oci 2.135.0__py3-none-any.whl → 2.135.2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- oci/__init__.py +2 -2
- oci/access_governance_cp/access_governance_cp_client.py +8 -8
- oci/adm/application_dependency_management_client.py +36 -36
- oci/ai_anomaly_detection/anomaly_detection_client.py +36 -36
- oci/ai_document/ai_service_document_client.py +26 -26
- oci/ai_language/ai_service_language_client.py +44 -44
- oci/ai_speech/ai_service_speech_client.py +19 -19
- oci/ai_vision/ai_service_vision_client.py +25 -25
- oci/analytics/analytics_client.py +24 -24
- oci/announcements_service/announcement_client.py +5 -5
- oci/announcements_service/announcement_subscription_client.py +9 -9
- oci/announcements_service/announcements_preferences_client.py +4 -4
- oci/announcements_service/service_client.py +1 -1
- oci/apigateway/api_gateway_client.py +21 -21
- oci/apigateway/deployment_client.py +6 -6
- oci/apigateway/gateway_client.py +6 -6
- oci/apigateway/subscribers_client.py +6 -6
- oci/apigateway/usage_plans_client.py +6 -6
- oci/apigateway/work_requests_client.py +5 -5
- oci/apm_config/config_client.py +9 -9
- oci/apm_control_plane/apm_domain_client.py +14 -14
- oci/apm_synthetics/apm_synthetic_client.py +28 -28
- oci/apm_traces/attributes_client.py +8 -8
- oci/apm_traces/query_client.py +2 -2
- oci/apm_traces/trace_client.py +4 -4
- oci/appmgmt_control/appmgmt_control_client.py +8 -8
- oci/artifacts/artifacts_client.py +32 -32
- oci/audit/audit_client.py +3 -3
- oci/autoscaling/auto_scaling_client.py +11 -11
- oci/bastion/bastion_client.py +15 -15
- oci/bds/bds_client.py +72 -72
- oci/blockchain/blockchain_platform_client.py +27 -27
- oci/budget/budget_client.py +10 -10
- oci/capacity_management/capacity_management_client.py +32 -32
- oci/certificates/certificates_client.py +5 -5
- oci/certificates_management/certificates_management_client.py +32 -32
- oci/cims/incident_client.py +8 -8
- oci/cims/user_client.py +1 -1
- oci/cloud_bridge/common_client.py +5 -5
- oci/cloud_bridge/discovery_client.py +14 -14
- oci/cloud_bridge/inventory_client.py +16 -16
- oci/cloud_bridge/ocb_agent_svc_client.py +23 -23
- oci/cloud_guard/cloud_guard_client.py +155 -155
- oci/cloud_migrations/migration_client.py +43 -43
- oci/cluster_placement_groups/cluster_placement_groups_cp_client.py +13 -13
- oci/compute_cloud_at_customer/compute_cloud_at_customer_client.py +12 -12
- oci/compute_instance_agent/compute_instance_agent_client.py +6 -6
- oci/compute_instance_agent/plugin_client.py +2 -2
- oci/compute_instance_agent/pluginconfig_client.py +1 -1
- oci/container_engine/container_engine_client.py +98 -94
- oci/container_engine/models/cluster.py +6 -2
- oci/container_engine/models/cluster_summary.py +6 -2
- oci/container_engine/models/node.py +6 -2
- oci/container_engine/models/node_pool.py +6 -2
- oci/container_engine/models/node_pool_summary.py +6 -2
- oci/container_engine/models/start_credential_rotation_details.py +2 -2
- oci/container_engine/models/work_request.py +7 -3
- oci/container_engine/models/work_request_summary.py +7 -3
- oci/container_engine/models/workload_mapping.py +35 -2
- oci/container_engine/models/workload_mapping_summary.py +35 -2
- oci/container_instances/container_instance_client.py +18 -18
- oci/core/blockstorage_client.py +60 -60
- oci/core/compute_client.py +108 -102
- oci/core/compute_management_client.py +32 -32
- oci/core/models/__init__.py +2 -0
- oci/core/models/add_network_security_group_security_rules_details.py +6 -2
- oci/core/models/create_service_gateway_details.py +2 -2
- oci/core/models/create_vcn_details.py +35 -0
- oci/core/models/create_vnic_details.py +35 -0
- oci/core/models/instance.py +82 -0
- oci/core/models/instance_configuration_create_vnic_details.py +35 -0
- oci/core/models/instance_configuration_launch_instance_details.py +35 -0
- oci/core/models/launch_attach_paravirtualized_volume_details.py +123 -0
- oci/core/models/launch_attach_volume_details.py +4 -0
- oci/core/models/launch_instance_details.py +35 -0
- oci/core/models/service_gateway.py +4 -4
- oci/core/models/update_instance_details.py +35 -0
- oci/core/models/update_vcn_details.py +37 -2
- oci/core/models/update_vnic_details.py +35 -0
- oci/core/models/vcn.py +35 -0
- oci/core/models/vnic.py +35 -0
- oci/core/virtual_network_client.py +253 -250
- oci/dashboard_service/dashboard_client.py +6 -6
- oci/dashboard_service/dashboard_group_client.py +6 -6
- oci/data_catalog/data_catalog_client.py +149 -149
- oci/data_flow/data_flow_client.py +42 -42
- oci/data_integration/data_integration_client.py +163 -163
- oci/data_labeling_service/data_labeling_management_client.py +17 -17
- oci/data_labeling_service_dataplane/data_labeling_client.py +15 -15
- oci/data_safe/data_safe_client.py +292 -292
- oci/data_science/data_science_client.py +91 -91
- oci/database/database_client.py +396 -396
- oci/database/models/autonomous_database.py +39 -0
- oci/database/models/autonomous_database_summary.py +39 -0
- oci/database/models/cloud_autonomous_vm_cluster.py +39 -0
- oci/database/models/cloud_autonomous_vm_cluster_summary.py +39 -0
- oci/database/models/cloud_vm_cluster.py +68 -2
- oci/database/models/cloud_vm_cluster_summary.py +68 -2
- oci/database/models/create_autonomous_database_base.py +39 -0
- oci/database/models/create_autonomous_database_clone_details.py +7 -0
- oci/database/models/create_autonomous_database_details.py +7 -0
- oci/database/models/create_autonomous_database_from_backup_details.py +7 -0
- oci/database/models/create_autonomous_database_from_backup_timestamp_details.py +7 -0
- oci/database/models/create_cloud_autonomous_vm_cluster_details.py +41 -2
- oci/database/models/create_cloud_vm_cluster_details.py +68 -2
- oci/database/models/create_cross_region_autonomous_database_data_guard_details.py +7 -0
- oci/database/models/create_cross_region_disaster_recovery_details.py +7 -0
- oci/database/models/create_cross_tenancy_disaster_recovery_details.py +7 -0
- oci/database/models/create_data_guard_association_with_new_db_system_details.py +39 -0
- oci/database/models/create_exadb_vm_cluster_details.py +39 -0
- oci/database/models/create_refreshable_autonomous_database_clone_details.py +7 -0
- oci/database/models/create_vm_cluster_details.py +29 -2
- oci/database/models/db_system.py +39 -0
- oci/database/models/db_system_summary.py +39 -0
- oci/database/models/exadb_vm_cluster.py +39 -0
- oci/database/models/exadb_vm_cluster_summary.py +39 -0
- oci/database/models/launch_db_system_base.py +39 -0
- oci/database/models/launch_db_system_details.py +7 -0
- oci/database/models/launch_db_system_from_backup_details.py +7 -0
- oci/database/models/launch_db_system_from_database_details.py +7 -0
- oci/database/models/launch_db_system_from_db_system_details.py +7 -0
- oci/database/models/undelete_autonomous_database_details.py +7 -0
- oci/database/models/update_autonomous_database_details.py +39 -0
- oci/database/models/update_cloud_autonomous_vm_cluster_details.py +41 -2
- oci/database/models/update_cloud_vm_cluster_details.py +68 -2
- oci/database/models/update_db_system_details.py +39 -0
- oci/database/models/update_exadb_vm_cluster_details.py +39 -0
- oci/database/models/update_vm_cluster_details.py +29 -2
- oci/database/models/vm_cluster.py +29 -2
- oci/database/models/vm_cluster_summary.py +29 -2
- oci/database_management/db_management_client.py +211 -211
- oci/database_management/diagnosability_client.py +4 -4
- oci/database_management/managed_my_sql_databases_client.py +7 -7
- oci/database_management/perfhub_client.py +1 -1
- oci/database_management/sql_tuning_client.py +17 -17
- oci/database_migration/database_migration_client.py +42 -42
- oci/database_tools/database_tools_client.py +23 -23
- oci/delegate_access_control/delegate_access_control_client.py +26 -26
- oci/delegate_access_control/work_request_client.py +4 -4
- oci/demand_signal/occ_demand_signal_client.py +7 -7
- oci/desktops/desktop_service_client.py +33 -22
- oci/desktops/models/__init__.py +18 -0
- oci/desktops/models/create_desktop_pool_desktop_session_lifecycle_actions.py +95 -0
- oci/desktops/models/create_desktop_pool_details.py +136 -4
- oci/desktops/models/create_desktop_pool_private_access_details.py +142 -0
- oci/desktops/models/create_desktop_pool_shape_config_details.py +170 -0
- oci/desktops/models/desktop_image.py +33 -2
- oci/desktops/models/desktop_network_configuration.py +14 -4
- oci/desktops/models/desktop_pool.py +136 -4
- oci/desktops/models/desktop_pool_private_access_details.py +212 -0
- oci/desktops/models/desktop_pool_shape_config.py +170 -0
- oci/desktops/models/desktop_session_lifecycle_actions.py +95 -0
- oci/desktops/models/disconnect_config.py +121 -0
- oci/desktops/models/inactivity_config.py +121 -0
- oci/desktops/models/update_desktop_pool_desktop_session_lifecycle_actions.py +95 -0
- oci/desktops/models/update_desktop_pool_details.py +29 -2
- oci/devops/devops_client.py +141 -141
- oci/disaster_recovery/disaster_recovery_client.py +29 -29
- oci/dns/dns_client.py +52 -52
- oci/dts/appliance_export_job_client.py +6 -6
- oci/dts/shipping_vendors_client.py +1 -1
- oci/dts/transfer_appliance_client.py +8 -8
- oci/dts/transfer_appliance_entitlement_client.py +3 -3
- oci/dts/transfer_device_client.py +5 -5
- oci/dts/transfer_job_client.py +6 -6
- oci/dts/transfer_package_client.py +7 -7
- oci/em_warehouse/em_data_lake_client.py +13 -13
- oci/em_warehouse/em_warehouse_client.py +13 -13
- oci/email/email_client.py +31 -31
- oci/email_data_plane/email_dp_client.py +1 -1
- oci/events/events_client.py +6 -6
- oci/file_storage/file_storage_client.py +54 -54
- oci/fleet_apps_management/fleet_apps_management_admin_client.py +8 -8
- oci/fleet_apps_management/fleet_apps_management_client.py +35 -35
- oci/fleet_apps_management/fleet_apps_management_maintenance_window_client.py +5 -5
- oci/fleet_apps_management/fleet_apps_management_operations_client.py +13 -13
- oci/fleet_apps_management/fleet_apps_management_runbooks_client.py +4 -4
- oci/fleet_software_update/fleet_software_update_client.py +46 -46
- oci/functions/functions_invoke_client.py +1 -1
- oci/functions/functions_management_client.py +16 -16
- oci/fusion_apps/data_masking_activity_client.py +3 -3
- oci/fusion_apps/fusion_applications_client.py +42 -42
- oci/fusion_apps/fusion_environment_client.py +15 -15
- oci/fusion_apps/fusion_environment_family_client.py +8 -8
- oci/fusion_apps/models/create_fusion_environment_admin_user_details.py +1 -1
- oci/fusion_apps/refresh_activity_client.py +4 -4
- oci/fusion_apps/scheduled_activity_client.py +2 -2
- oci/fusion_apps/service_attachment_client.py +2 -2
- oci/generative_ai/generative_ai_client.py +22 -22
- oci/generative_ai_agent/generative_ai_agent_client.py +33 -33
- oci/generative_ai_agent_runtime/generative_ai_agent_runtime_client.py +5 -5
- oci/generative_ai_inference/generative_ai_inference_client.py +4 -4
- oci/generic_artifacts_content/generic_artifacts_content_client.py +3 -3
- oci/globally_distributed_database/sharded_database_service_client.py +30 -30
- oci/golden_gate/golden_gate_client.py +68 -68
- oci/governance_rules_control_plane/governance_rule_client.py +15 -15
- oci/governance_rules_control_plane/work_request_client.py +5 -5
- oci/healthchecks/health_checks_client.py +17 -17
- oci/identity/identity_client.py +145 -145
- oci/identity_data_plane/dataplane_client.py +2 -2
- oci/identity_domains/identity_domains_client.py +307 -307
- oci/integration/integration_instance_client.py +137 -18
- oci/integration/integration_instance_client_composite_operations.py +39 -0
- oci/integration/models/__init__.py +4 -0
- oci/integration/models/create_integration_instance_details.py +31 -0
- oci/integration/models/cross_region_integration_instance_details.py +185 -0
- oci/integration/models/disaster_recovery_details.py +150 -0
- oci/integration/models/integration_instance.py +89 -0
- oci/integration/models/integration_instance_summary.py +62 -0
- oci/integration/models/work_request.py +7 -3
- oci/integration/models/work_request_summary.py +7 -3
- oci/jms/java_management_service_client.py +75 -75
- oci/jms_java_downloads/java_download_client.py +25 -25
- oci/key_management/ekm_client.py +5 -5
- oci/key_management/kms_crypto_client.py +6 -6
- oci/key_management/kms_hsm_cluster_client.py +12 -12
- oci/key_management/kms_management_client.py +21 -21
- oci/key_management/kms_vault_client.py +14 -14
- oci/license_manager/license_manager_client.py +18 -18
- oci/limits/limits_client.py +4 -4
- oci/limits/quotas_client.py +7 -7
- oci/load_balancer/load_balancer_client.py +61 -61
- oci/load_balancer/models/connection_configuration.py +47 -2
- oci/load_balancer/models/create_load_balancer_details.py +35 -0
- oci/load_balancer/models/load_balancer.py +35 -0
- oci/load_balancer/models/update_load_balancer_details.py +37 -2
- oci/lockbox/lockbox_client.py +24 -24
- oci/log_analytics/log_analytics_client.py +193 -193
- oci/logging/logging_management_client.py +30 -30
- oci/loggingingestion/logging_client.py +1 -1
- oci/loggingsearch/log_search_client.py +1 -1
- oci/management_agent/management_agent_client.py +28 -28
- oci/management_dashboard/dashx_apis_client.py +14 -14
- oci/marketplace/account_client.py +2 -2
- oci/marketplace/marketplace_client.py +30 -30
- oci/marketplace_private_offer/attachment_client.py +5 -5
- oci/marketplace_private_offer/offer_client.py +6 -6
- oci/marketplace_publisher/attachment_client.py +5 -5
- oci/marketplace_publisher/marketplace_publisher_client.py +71 -71
- oci/marketplace_publisher/offer_client.py +6 -6
- oci/media_services/media_services_client.py +60 -60
- oci/media_services/media_stream_client.py +2 -2
- oci/monitoring/monitoring_client.py +18 -18
- oci/mysql/channels_client.py +7 -7
- oci/mysql/db_backups_client.py +7 -7
- oci/mysql/db_system_client.py +17 -17
- oci/mysql/mysqlaas_client.py +7 -7
- oci/mysql/replicas_client.py +5 -5
- oci/mysql/work_requests_client.py +4 -4
- oci/network_firewall/network_firewall_client.py +86 -86
- oci/network_load_balancer/models/create_network_load_balancer_details.py +43 -2
- oci/network_load_balancer/models/network_load_balancer.py +41 -0
- oci/network_load_balancer/models/network_load_balancer_summary.py +41 -0
- oci/network_load_balancer/models/update_network_load_balancer_details.py +43 -2
- oci/network_load_balancer/network_load_balancer_client.py +34 -34
- oci/nosql/nosql_client.py +24 -24
- oci/object_storage/object_storage_client.py +55 -55
- oci/oce/oce_instance_client.py +10 -10
- oci/oci_control_center/occ_metrics_client.py +3 -3
- oci/ocvp/cluster_client.py +5 -5
- oci/ocvp/esxi_host_client.py +8 -8
- oci/ocvp/sddc_client.py +14 -14
- oci/ocvp/work_request_client.py +4 -4
- oci/oda/management_client.py +59 -59
- oci/oda/oda_client.py +17 -17
- oci/oda/odapackage_client.py +7 -7
- oci/onesubscription/billing_schedule_client.py +1 -1
- oci/onesubscription/commitment_client.py +2 -2
- oci/onesubscription/computed_usage_client.py +3 -3
- oci/onesubscription/invoice_summary_client.py +2 -2
- oci/onesubscription/organization_subscription_client.py +1 -1
- oci/onesubscription/ratecard_client.py +1 -1
- oci/onesubscription/subscribed_service_client.py +2 -2
- oci/onesubscription/subscription_client.py +1 -1
- oci/ons/notification_control_plane_client.py +6 -6
- oci/ons/notification_data_plane_client.py +10 -10
- oci/opa/opa_instance_client.py +13 -13
- oci/opensearch/opensearch_cluster_backup_client.py +4 -4
- oci/opensearch/opensearch_cluster_client.py +14 -14
- oci/operator_access_control/access_requests_client.py +10 -10
- oci/operator_access_control/operator_actions_client.py +2 -2
- oci/operator_access_control/operator_control_assignment_client.py +8 -8
- oci/operator_access_control/operator_control_client.py +6 -6
- oci/opsi/models/__init__.py +6 -0
- oci/opsi/models/create_autonomous_database_insight_details.py +291 -0
- oci/opsi/models/create_database_insight_details.py +4 -0
- oci/opsi/models/credential_by_iam.py +58 -0
- oci/opsi/models/credential_by_vault.py +1 -1
- oci/opsi/models/credential_details.py +13 -5
- oci/opsi/models/credentials_by_source.py +1 -1
- oci/opsi/models/enable_autonomous_database_insight_details.py +301 -0
- oci/opsi/models/enable_database_insight_details.py +4 -0
- oci/opsi/operations_insights_client.py +179 -179
- oci/optimizer/optimizer_client.py +26 -26
- oci/os_management/event_client.py +8 -8
- oci/os_management/os_management_client.py +69 -69
- oci/os_management_hub/event_client.py +8 -8
- oci/os_management_hub/lifecycle_environment_client.py +12 -12
- oci/os_management_hub/managed_instance_client.py +31 -31
- oci/os_management_hub/managed_instance_group_client.py +25 -25
- oci/os_management_hub/management_station_client.py +10 -10
- oci/os_management_hub/onboarding_client.py +6 -6
- oci/os_management_hub/reporting_managed_instance_client.py +3 -3
- oci/os_management_hub/scheduled_job_client.py +7 -7
- oci/os_management_hub/software_source_client.py +27 -27
- oci/os_management_hub/work_request_client.py +4 -4
- oci/osp_gateway/address_rule_service_client.py +1 -1
- oci/osp_gateway/address_service_client.py +2 -2
- oci/osp_gateway/invoice_service_client.py +5 -5
- oci/osp_gateway/subscription_service_client.py +5 -5
- oci/osub_billing_schedule/billing_schedule_client.py +1 -1
- oci/osub_organization_subscription/organization_subscription_client.py +1 -1
- oci/osub_subscription/commitment_client.py +2 -2
- oci/osub_subscription/ratecard_client.py +1 -1
- oci/osub_subscription/subscription_client.py +1 -1
- oci/osub_usage/computed_usage_client.py +3 -3
- oci/psql/postgresql_client.py +33 -33
- oci/queue/queue_admin_client.py +11 -11
- oci/queue/queue_client.py +8 -8
- oci/recovery/database_recovery_client.py +26 -26
- oci/redis/redis_cluster_client.py +12 -12
- oci/regions_definitions.py +8 -0
- oci/resource_manager/resource_manager_client.py +52 -52
- oci/resource_scheduler/schedule_client.py +13 -13
- oci/resource_search/resource_search_client.py +3 -3
- oci/rover/rover_bundle_client.py +8 -8
- oci/rover/rover_cluster_client.py +8 -8
- oci/rover/rover_entitlement_client.py +6 -6
- oci/rover/rover_node_client.py +15 -15
- oci/rover/shape_client.py +1 -1
- oci/rover/work_requests_client.py +5 -5
- oci/sch/connector_plugins_client.py +2 -2
- oci/sch/service_connector_client.py +12 -12
- oci/secrets/secrets_client.py +3 -3
- oci/security_attribute/__init__.py +14 -0
- oci/security_attribute/models/__init__.py +54 -0
- oci/security_attribute/models/base_security_attribute_validator.py +122 -0
- oci/security_attribute/models/bulk_delete_security_attributes_details.py +72 -0
- oci/security_attribute/models/bulk_edit_resource.py +134 -0
- oci/security_attribute/models/bulk_edit_security_attribute_details.py +134 -0
- oci/security_attribute/models/bulk_edit_security_attribute_operation_details.py +147 -0
- oci/security_attribute/models/change_security_attribute_namespace_compartment_details.py +72 -0
- oci/security_attribute/models/create_security_attribute_details.py +132 -0
- oci/security_attribute/models/create_security_attribute_namespace_details.py +216 -0
- oci/security_attribute/models/default_security_attribute_validator.py +53 -0
- oci/security_attribute/models/enum_security_attribute_validator.py +85 -0
- oci/security_attribute/models/security_attribute.py +421 -0
- oci/security_attribute/models/security_attribute_namespace.py +446 -0
- oci/security_attribute/models/security_attribute_namespace_summary.py +410 -0
- oci/security_attribute/models/security_attribute_summary.py +361 -0
- oci/security_attribute/models/security_attribute_work_request.py +387 -0
- oci/security_attribute/models/security_attribute_work_request_error_summary.py +136 -0
- oci/security_attribute/models/security_attribute_work_request_log_summary.py +105 -0
- oci/security_attribute/models/security_attribute_work_request_summary.py +386 -0
- oci/security_attribute/models/update_security_attribute_details.py +136 -0
- oci/security_attribute/models/update_security_attribute_namespace_details.py +191 -0
- oci/security_attribute/models/work_request_resource.py +197 -0
- oci/security_attribute/security_attribute_client.py +2321 -0
- oci/security_attribute/security_attribute_client_composite_operations.py +265 -0
- oci/service_catalog/service_catalog_client.py +26 -26
- oci/service_manager_proxy/service_manager_proxy_client.py +2 -2
- oci/service_mesh/service_mesh_client.py +48 -48
- oci/stack_monitoring/models/__init__.py +20 -0
- oci/stack_monitoring/models/create_maintenance_window_details.py +196 -0
- oci/stack_monitoring/models/create_maintenance_window_resource_details.py +111 -0
- oci/stack_monitoring/models/maintenance_window.py +439 -0
- oci/stack_monitoring/models/maintenance_window_collection.py +72 -0
- oci/stack_monitoring/models/maintenance_window_schedule.py +109 -0
- oci/stack_monitoring/models/maintenance_window_summary.py +519 -0
- oci/stack_monitoring/models/monitored_resource_details.py +171 -0
- oci/stack_monitoring/models/one_time_maintenance_window_schedule.py +113 -0
- oci/stack_monitoring/models/recurrent_maintenance_window_schedule.py +191 -0
- oci/stack_monitoring/models/update_maintenance_window_details.py +130 -0
- oci/stack_monitoring/models/work_request.py +19 -3
- oci/stack_monitoring/models/work_request_summary.py +19 -3
- oci/stack_monitoring/stack_monitoring_client.py +921 -113
- oci/stack_monitoring/stack_monitoring_client_composite_operations.py +214 -0
- oci/streaming/stream_admin_client.py +18 -18
- oci/streaming/stream_client.py +8 -8
- oci/tenant_manager_control_plane/domain_client.py +5 -5
- oci/tenant_manager_control_plane/domain_governance_client.py +5 -5
- oci/tenant_manager_control_plane/governance_client.py +2 -2
- oci/tenant_manager_control_plane/link_client.py +3 -3
- oci/tenant_manager_control_plane/orders_client.py +2 -2
- oci/tenant_manager_control_plane/organization_client.py +10 -10
- oci/tenant_manager_control_plane/recipient_invitation_client.py +5 -5
- oci/tenant_manager_control_plane/sender_invitation_client.py +5 -5
- oci/tenant_manager_control_plane/subscription_client.py +11 -11
- oci/tenant_manager_control_plane/work_request_client.py +4 -4
- oci/threat_intelligence/threatintel_client.py +5 -5
- oci/usage/resources_client.py +2 -2
- oci/usage/rewards_client.py +6 -6
- oci/usage/usagelimits_client.py +1 -1
- oci/usage_api/usageapi_client.py +33 -33
- oci/vault/vaults_client.py +13 -13
- oci/vbs_inst/vbs_instance_client.py +10 -10
- oci/version.py +1 -1
- oci/visual_builder/vb_instance_client.py +13 -13
- oci/vn_monitoring/vn_monitoring_client.py +12 -12
- oci/vulnerability_scanning/vulnerability_scanning_client.py +58 -58
- oci/waa/waa_client.py +13 -13
- oci/waa/work_request_client.py +4 -4
- oci/waas/redirect_client.py +6 -6
- oci/waas/waas_client.py +66 -66
- oci/waf/waf_client.py +24 -24
- oci/work_requests/work_request_client.py +4 -4
- oci/zpr/__init__.py +14 -0
- oci/zpr/models/__init__.py +42 -0
- oci/zpr/models/configuration.py +449 -0
- oci/zpr/models/create_configuration_details.py +189 -0
- oci/zpr/models/create_zpr_policy_details.py +251 -0
- oci/zpr/models/update_zpr_policy_details.py +185 -0
- oci/zpr/models/work_request.py +459 -0
- oci/zpr/models/work_request_error.py +146 -0
- oci/zpr/models/work_request_error_collection.py +72 -0
- oci/zpr/models/work_request_log_entry.py +109 -0
- oci/zpr/models/work_request_log_entry_collection.py +72 -0
- oci/zpr/models/work_request_resource.py +238 -0
- oci/zpr/models/work_request_summary.py +457 -0
- oci/zpr/models/work_request_summary_collection.py +72 -0
- oci/zpr/models/zpr_policy.py +505 -0
- oci/zpr/models/zpr_policy_collection.py +72 -0
- oci/zpr/models/zpr_policy_summary.py +463 -0
- oci/zpr/zpr_client.py +2123 -0
- oci/zpr/zpr_client_composite_operations.py +197 -0
- {oci-2.135.0.dist-info → oci-2.135.2.dist-info}/METADATA +2 -2
- {oci-2.135.0.dist-info → oci-2.135.2.dist-info}/RECORD +431 -362
- {oci-2.135.0.dist-info → oci-2.135.2.dist-info}/LICENSE.txt +0 -0
- {oci-2.135.0.dist-info → oci-2.135.2.dist-info}/THIRD_PARTY_LICENSES.txt +0 -0
- {oci-2.135.0.dist-info → oci-2.135.2.dist-info}/WHEEL +0 -0
- {oci-2.135.0.dist-info → oci-2.135.2.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,2321 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
# Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved.
|
3
|
+
# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
|
4
|
+
|
5
|
+
# NOTE: This class is auto generated by OracleSDKGenerator. DO NOT EDIT. API Version: 20240815
|
6
|
+
|
7
|
+
from __future__ import absolute_import
|
8
|
+
|
9
|
+
from oci._vendor import requests # noqa: F401
|
10
|
+
from oci._vendor import six
|
11
|
+
|
12
|
+
from oci import retry, circuit_breaker # noqa: F401
|
13
|
+
from oci.base_client import BaseClient
|
14
|
+
from oci.config import get_config_value_or_default, validate_config
|
15
|
+
from oci.signer import Signer
|
16
|
+
from oci.util import Sentinel, get_signer_from_authentication_type, AUTHENTICATION_TYPE_FIELD_NAME
|
17
|
+
from oci.exceptions import InvalidAlloyConfig
|
18
|
+
from oci.alloy import OCI_SDK_ENABLED_SERVICES_SET
|
19
|
+
from .models import security_attribute_type_mapping
|
20
|
+
missing = Sentinel("Missing")
|
21
|
+
|
22
|
+
|
23
|
+
class SecurityAttributeClient(object):
|
24
|
+
"""
|
25
|
+
Use the Security Attributes API to manage security attributes and security attribute namespaces. For more information, see the documentation for [Security Attributes](/iaas/Content/zero-trust-packet-routing/managing-security-attributes.htm) and [Security Attribute Nampespaces](/iaas/Content/zero-trust-packet-routing/managing-security-attribute-namespaces.htm).
|
26
|
+
"""
|
27
|
+
|
28
|
+
def __init__(self, config, **kwargs):
|
29
|
+
"""
|
30
|
+
Creates a new service client
|
31
|
+
|
32
|
+
:param dict config:
|
33
|
+
Configuration keys and values as per `SDK and Tool Configuration <https://docs.cloud.oracle.com/Content/API/Concepts/sdkconfig.htm>`__.
|
34
|
+
The :py:meth:`~oci.config.from_file` method can be used to load configuration from a file. Alternatively, a ``dict`` can be passed. You can validate_config
|
35
|
+
the dict using :py:meth:`~oci.config.validate_config`
|
36
|
+
|
37
|
+
:param str service_endpoint: (optional)
|
38
|
+
The endpoint of the service to call using this client. For example ``https://iaas.us-ashburn-1.oraclecloud.com``. If this keyword argument is
|
39
|
+
not provided then it will be derived using the region in the config parameter. You should only provide this keyword argument if you have an explicit
|
40
|
+
need to specify a service endpoint.
|
41
|
+
|
42
|
+
:param timeout: (optional)
|
43
|
+
The connection and read timeouts for the client. The default values are connection timeout 10 seconds and read timeout 60 seconds. This keyword argument can be provided
|
44
|
+
as a single float, in which case the value provided is used for both the read and connection timeouts, or as a tuple of two floats. If
|
45
|
+
a tuple is provided then the first value is used as the connection timeout and the second value as the read timeout.
|
46
|
+
:type timeout: float or tuple(float, float)
|
47
|
+
|
48
|
+
:param signer: (optional)
|
49
|
+
The signer to use when signing requests made by the service client. The default is to use a :py:class:`~oci.signer.Signer` based on the values
|
50
|
+
provided in the config parameter.
|
51
|
+
|
52
|
+
One use case for this parameter is for `Instance Principals authentication <https://docs.cloud.oracle.com/Content/Identity/Tasks/callingservicesfrominstances.htm>`__
|
53
|
+
by passing an instance of :py:class:`~oci.auth.signers.InstancePrincipalsSecurityTokenSigner` as the value for this keyword argument
|
54
|
+
:type signer: :py:class:`~oci.signer.AbstractBaseSigner`
|
55
|
+
|
56
|
+
:param obj retry_strategy: (optional)
|
57
|
+
A retry strategy to apply to all calls made by this service client (i.e. at the client level). There is no retry strategy applied by default.
|
58
|
+
Retry strategies can also be applied at the operation level by passing a ``retry_strategy`` keyword argument as part of calling the operation.
|
59
|
+
Any value provided at the operation level will override whatever is specified at the client level.
|
60
|
+
|
61
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. A convenience :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY`
|
62
|
+
is also available. The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
63
|
+
|
64
|
+
:param obj circuit_breaker_strategy: (optional)
|
65
|
+
A circuit breaker strategy to apply to all calls made by this service client (i.e. at the client level).
|
66
|
+
This client uses :py:data:`~oci.circuit_breaker.DEFAULT_CIRCUIT_BREAKER_STRATEGY` as default if no circuit breaker strategy is provided.
|
67
|
+
The specifics of circuit breaker strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/circuit_breakers.html>`__.
|
68
|
+
|
69
|
+
:param function circuit_breaker_callback: (optional)
|
70
|
+
Callback function to receive any exceptions triggerred by the circuit breaker.
|
71
|
+
|
72
|
+
:param bool client_level_realm_specific_endpoint_template_enabled: (optional)
|
73
|
+
A boolean flag to indicate whether or not this client should be created with realm specific endpoint template enabled or disable. By default, this will be set as None.
|
74
|
+
|
75
|
+
:param allow_control_chars: (optional)
|
76
|
+
allow_control_chars is a boolean to indicate whether or not this client should allow control characters in the response object. By default, the client will not
|
77
|
+
allow control characters to be in the response object.
|
78
|
+
"""
|
79
|
+
if not OCI_SDK_ENABLED_SERVICES_SET.is_service_enabled("security_attribute"):
|
80
|
+
raise InvalidAlloyConfig("The Alloy configuration has disabled this service, this behavior is controlled by OCI_SDK_ENABLED_SERVICES_SET variable. Please check if your local alloy-config file configured the service you're targeting or contact the cloud provider on the availability of this service")
|
81
|
+
|
82
|
+
validate_config(config, signer=kwargs.get('signer'))
|
83
|
+
if 'signer' in kwargs:
|
84
|
+
signer = kwargs['signer']
|
85
|
+
|
86
|
+
elif AUTHENTICATION_TYPE_FIELD_NAME in config:
|
87
|
+
signer = get_signer_from_authentication_type(config)
|
88
|
+
|
89
|
+
else:
|
90
|
+
signer = Signer(
|
91
|
+
tenancy=config["tenancy"],
|
92
|
+
user=config["user"],
|
93
|
+
fingerprint=config["fingerprint"],
|
94
|
+
private_key_file_location=config.get("key_file"),
|
95
|
+
pass_phrase=get_config_value_or_default(config, "pass_phrase"),
|
96
|
+
private_key_content=config.get("key_content")
|
97
|
+
)
|
98
|
+
|
99
|
+
base_client_init_kwargs = {
|
100
|
+
'regional_client': True,
|
101
|
+
'service_endpoint': kwargs.get('service_endpoint'),
|
102
|
+
'base_path': '/20240815',
|
103
|
+
'service_endpoint_template': 'https://security-attribute.{region}.oci.{secondLevelDomain}',
|
104
|
+
'service_endpoint_template_per_realm': { }, # noqa: E201 E202
|
105
|
+
'skip_deserialization': kwargs.get('skip_deserialization', False),
|
106
|
+
'circuit_breaker_strategy': kwargs.get('circuit_breaker_strategy', circuit_breaker.GLOBAL_CIRCUIT_BREAKER_STRATEGY),
|
107
|
+
'client_level_realm_specific_endpoint_template_enabled': kwargs.get('client_level_realm_specific_endpoint_template_enabled')
|
108
|
+
}
|
109
|
+
if 'timeout' in kwargs:
|
110
|
+
base_client_init_kwargs['timeout'] = kwargs.get('timeout')
|
111
|
+
if base_client_init_kwargs.get('circuit_breaker_strategy') is None:
|
112
|
+
base_client_init_kwargs['circuit_breaker_strategy'] = circuit_breaker.DEFAULT_CIRCUIT_BREAKER_STRATEGY
|
113
|
+
if 'allow_control_chars' in kwargs:
|
114
|
+
base_client_init_kwargs['allow_control_chars'] = kwargs.get('allow_control_chars')
|
115
|
+
self.base_client = BaseClient("security_attribute", config, signer, security_attribute_type_mapping, **base_client_init_kwargs)
|
116
|
+
self.retry_strategy = kwargs.get('retry_strategy')
|
117
|
+
self.circuit_breaker_callback = kwargs.get('circuit_breaker_callback')
|
118
|
+
|
119
|
+
def bulk_delete_security_attributes(self, bulk_delete_security_attributes_details, **kwargs):
|
120
|
+
"""
|
121
|
+
Deletes the specified security attribute definitions. This operation triggers a process that removes the
|
122
|
+
security attributes from all resources in your tenancy. The security attributes must be within the same security attribute namespace.
|
123
|
+
|
124
|
+
The following actions happen immediately:
|
125
|
+
|
126
|
+
After you start this operation, the state of the tag changes to DELETING, and security attribute removal
|
127
|
+
from resources begins. This process can take up to 48 hours depending on the number of resources that
|
128
|
+
are tagged and the regions in which those resources reside.
|
129
|
+
|
130
|
+
When all security attributes have been removed, the state changes to DELETED. You cannot restore a deleted security attribute. After the security attribute state
|
131
|
+
changes to DELETED, you can use the same security attribute name again.
|
132
|
+
|
133
|
+
After you start this operation, you cannot start either the :func:`delete_security_attribute` or the :func:`cascade_delete_security_attribute_namespace` operation until this process completes.
|
134
|
+
|
135
|
+
In order to delete security attribute, you must first retire the security attribute. Use :func:`update_security_attribute`
|
136
|
+
to retire a security attribute.
|
137
|
+
|
138
|
+
|
139
|
+
:param oci.security_attribute.models.BulkDeleteSecurityAttributesDetails bulk_delete_security_attributes_details: (required)
|
140
|
+
Request object for deleting security attributes in bulk.
|
141
|
+
|
142
|
+
:param str opc_request_id: (optional)
|
143
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
144
|
+
Oracle about a particular request, please provide the request ID.
|
145
|
+
The only valid characters for request IDs are letters, numbers,
|
146
|
+
underscore, and dash.
|
147
|
+
|
148
|
+
:param str opc_retry_token: (optional)
|
149
|
+
A token that uniquely identifies a request so it can be retried in case of a timeout or
|
150
|
+
server error without risk of running that same action again. Retry tokens expire after 24
|
151
|
+
hours, but can be invalidated before then due to conflicting operations. For example, if a resource
|
152
|
+
has been deleted and removed from the system, then a retry of the original creation request
|
153
|
+
might be rejected.
|
154
|
+
|
155
|
+
:param obj retry_strategy: (optional)
|
156
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
157
|
+
|
158
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
159
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
160
|
+
|
161
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
162
|
+
|
163
|
+
:param bool allow_control_chars: (optional)
|
164
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
165
|
+
By default, the response will not allow control characters in strings
|
166
|
+
|
167
|
+
:return: A :class:`~oci.response.Response` object with data of type None
|
168
|
+
:rtype: :class:`~oci.response.Response`
|
169
|
+
|
170
|
+
:example:
|
171
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/bulk_delete_security_attributes.py.html>`__ to see an example of how to use bulk_delete_security_attributes API.
|
172
|
+
"""
|
173
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
174
|
+
required_arguments = []
|
175
|
+
resource_path = "/securityAttributes/actions/bulkDelete"
|
176
|
+
method = "POST"
|
177
|
+
operation_name = "bulk_delete_security_attributes"
|
178
|
+
api_reference_link = ""
|
179
|
+
|
180
|
+
# Don't accept unknown kwargs
|
181
|
+
expected_kwargs = [
|
182
|
+
"allow_control_chars",
|
183
|
+
"retry_strategy",
|
184
|
+
"opc_request_id",
|
185
|
+
"opc_retry_token"
|
186
|
+
]
|
187
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
188
|
+
if extra_kwargs:
|
189
|
+
raise ValueError(
|
190
|
+
f"bulk_delete_security_attributes got unknown kwargs: {extra_kwargs!r}")
|
191
|
+
|
192
|
+
header_params = {
|
193
|
+
"accept": "application/json",
|
194
|
+
"content-type": "application/json",
|
195
|
+
"opc-request-id": kwargs.get("opc_request_id", missing),
|
196
|
+
"opc-retry-token": kwargs.get("opc_retry_token", missing)
|
197
|
+
}
|
198
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
199
|
+
|
200
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
201
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
202
|
+
client_retry_strategy=self.retry_strategy
|
203
|
+
)
|
204
|
+
if retry_strategy is None:
|
205
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
206
|
+
|
207
|
+
if retry_strategy:
|
208
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
209
|
+
self.base_client.add_opc_retry_token_if_needed(header_params)
|
210
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
211
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
212
|
+
return retry_strategy.make_retrying_call(
|
213
|
+
self.base_client.call_api,
|
214
|
+
resource_path=resource_path,
|
215
|
+
method=method,
|
216
|
+
header_params=header_params,
|
217
|
+
body=bulk_delete_security_attributes_details,
|
218
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
219
|
+
operation_name=operation_name,
|
220
|
+
api_reference_link=api_reference_link,
|
221
|
+
required_arguments=required_arguments)
|
222
|
+
else:
|
223
|
+
return self.base_client.call_api(
|
224
|
+
resource_path=resource_path,
|
225
|
+
method=method,
|
226
|
+
header_params=header_params,
|
227
|
+
body=bulk_delete_security_attributes_details,
|
228
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
229
|
+
operation_name=operation_name,
|
230
|
+
api_reference_link=api_reference_link,
|
231
|
+
required_arguments=required_arguments)
|
232
|
+
|
233
|
+
def bulk_edit_security_attributes(self, **kwargs):
|
234
|
+
"""
|
235
|
+
Edits the specified list of security attributes for the selected resources.
|
236
|
+
This operation triggers a process that edits the attributes on all selected resources. The possible actions are:
|
237
|
+
|
238
|
+
* Add a security attribute when it does not already exist on the resource.
|
239
|
+
* Update the value for a security attribute when it is present on the resource.
|
240
|
+
* Add a security attribute when it does not already exist on the resource or update the value when it is present on the resource.
|
241
|
+
* Remove a security attribute from a resource. The security attribute is removed from the resource regardless of the value.
|
242
|
+
|
243
|
+
The edits can include a combination of operations and attributes.
|
244
|
+
However, multiple operations cannot apply to the same attribute in the same request.
|
245
|
+
|
246
|
+
|
247
|
+
:param str opc_request_id: (optional)
|
248
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
249
|
+
Oracle about a particular request, please provide the request ID.
|
250
|
+
The only valid characters for request IDs are letters, numbers,
|
251
|
+
underscore, and dash.
|
252
|
+
|
253
|
+
:param str opc_retry_token: (optional)
|
254
|
+
A token that uniquely identifies a request so it can be retried in case of a timeout or
|
255
|
+
server error without risk of running that same action again. Retry tokens expire after 24
|
256
|
+
hours, but can be invalidated before then due to conflicting operations. For example, if a resource
|
257
|
+
has been deleted and removed from the system, then a retry of the original creation request
|
258
|
+
might be rejected.
|
259
|
+
|
260
|
+
:param oci.security_attribute.models.BulkEditSecurityAttributeDetails bulk_edit_security_attribute_details: (optional)
|
261
|
+
The request object for bulk editing security attributes on resources in the compartment.
|
262
|
+
|
263
|
+
:param obj retry_strategy: (optional)
|
264
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
265
|
+
|
266
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
267
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
268
|
+
|
269
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
270
|
+
|
271
|
+
:param bool allow_control_chars: (optional)
|
272
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
273
|
+
By default, the response will not allow control characters in strings
|
274
|
+
|
275
|
+
:return: A :class:`~oci.response.Response` object with data of type None
|
276
|
+
:rtype: :class:`~oci.response.Response`
|
277
|
+
|
278
|
+
:example:
|
279
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/bulk_edit_security_attributes.py.html>`__ to see an example of how to use bulk_edit_security_attributes API.
|
280
|
+
"""
|
281
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
282
|
+
required_arguments = []
|
283
|
+
resource_path = "/securityAttributes/actions/bulkEdit"
|
284
|
+
method = "POST"
|
285
|
+
operation_name = "bulk_edit_security_attributes"
|
286
|
+
api_reference_link = ""
|
287
|
+
|
288
|
+
# Don't accept unknown kwargs
|
289
|
+
expected_kwargs = [
|
290
|
+
"allow_control_chars",
|
291
|
+
"retry_strategy",
|
292
|
+
"opc_request_id",
|
293
|
+
"opc_retry_token",
|
294
|
+
"bulk_edit_security_attribute_details"
|
295
|
+
]
|
296
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
297
|
+
if extra_kwargs:
|
298
|
+
raise ValueError(
|
299
|
+
f"bulk_edit_security_attributes got unknown kwargs: {extra_kwargs!r}")
|
300
|
+
|
301
|
+
header_params = {
|
302
|
+
"accept": "application/json",
|
303
|
+
"content-type": "application/json",
|
304
|
+
"opc-request-id": kwargs.get("opc_request_id", missing),
|
305
|
+
"opc-retry-token": kwargs.get("opc_retry_token", missing)
|
306
|
+
}
|
307
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
308
|
+
|
309
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
310
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
311
|
+
client_retry_strategy=self.retry_strategy
|
312
|
+
)
|
313
|
+
if retry_strategy is None:
|
314
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
315
|
+
|
316
|
+
if retry_strategy:
|
317
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
318
|
+
self.base_client.add_opc_retry_token_if_needed(header_params)
|
319
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
320
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
321
|
+
return retry_strategy.make_retrying_call(
|
322
|
+
self.base_client.call_api,
|
323
|
+
resource_path=resource_path,
|
324
|
+
method=method,
|
325
|
+
header_params=header_params,
|
326
|
+
body=kwargs.get('bulk_edit_security_attribute_details'),
|
327
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
328
|
+
operation_name=operation_name,
|
329
|
+
api_reference_link=api_reference_link,
|
330
|
+
required_arguments=required_arguments)
|
331
|
+
else:
|
332
|
+
return self.base_client.call_api(
|
333
|
+
resource_path=resource_path,
|
334
|
+
method=method,
|
335
|
+
header_params=header_params,
|
336
|
+
body=kwargs.get('bulk_edit_security_attribute_details'),
|
337
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
338
|
+
operation_name=operation_name,
|
339
|
+
api_reference_link=api_reference_link,
|
340
|
+
required_arguments=required_arguments)
|
341
|
+
|
342
|
+
def cascading_delete_security_attribute_namespace(self, security_attribute_namespace_id, **kwargs):
|
343
|
+
"""
|
344
|
+
Deletes the specified security attribute namespace. This operation triggers a process that removes all of the security attributes
|
345
|
+
defined in the specified security attribute namespace from all resources in your tenancy and then deletes the security attribute namespace.
|
346
|
+
|
347
|
+
After you start the delete operation:
|
348
|
+
|
349
|
+
* New security attribute key definitions cannot be created under the namespace.
|
350
|
+
* The state of the security attribute namespace changes to DELETING.
|
351
|
+
* Security attribute removal from the resources begins.
|
352
|
+
|
353
|
+
This process can take up to 48 hours depending on the number of security attributes in the namespace, the number of resources
|
354
|
+
that are tagged, and the locations of the regions in which those resources reside.
|
355
|
+
|
356
|
+
After all security attributes are removed, the state changes to DELETED. You cannot restore a deleted security attribute namespace. After the deleted security attribute namespace
|
357
|
+
changes its state to DELETED, you can use the name of the deleted security attribute namespace again.
|
358
|
+
|
359
|
+
After you start this operation, you cannot start either the :func:`delete_security_attribute` or the :func:`bulk_delete_security_attributes` operation until this process completes.
|
360
|
+
|
361
|
+
To delete a security attribute namespace, you must first retire it. Use :func:`update_security_attribute_namespace`
|
362
|
+
to retire a security attribute namespace.
|
363
|
+
|
364
|
+
|
365
|
+
:param str security_attribute_namespace_id: (required)
|
366
|
+
The OCID of the security attribute namespace.
|
367
|
+
|
368
|
+
:param str if_match: (optional)
|
369
|
+
For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
|
370
|
+
`if-match` parameter to the value of the etag from a previous GET or POST response for
|
371
|
+
that resource. The resource will be updated or deleted only if the etag you provide
|
372
|
+
matches the resource's current etag value.
|
373
|
+
|
374
|
+
:param str opc_request_id: (optional)
|
375
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
376
|
+
Oracle about a particular request, please provide the request ID.
|
377
|
+
The only valid characters for request IDs are letters, numbers,
|
378
|
+
underscore, and dash.
|
379
|
+
|
380
|
+
:param str opc_retry_token: (optional)
|
381
|
+
A token that uniquely identifies a request so it can be retried in case of a timeout or
|
382
|
+
server error without risk of running that same action again. Retry tokens expire after 24
|
383
|
+
hours, but can be invalidated before then due to conflicting operations. For example, if a resource
|
384
|
+
has been deleted and removed from the system, then a retry of the original creation request
|
385
|
+
might be rejected.
|
386
|
+
|
387
|
+
:param obj retry_strategy: (optional)
|
388
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
389
|
+
|
390
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
391
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
392
|
+
|
393
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
394
|
+
|
395
|
+
:param bool allow_control_chars: (optional)
|
396
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
397
|
+
By default, the response will not allow control characters in strings
|
398
|
+
|
399
|
+
:return: A :class:`~oci.response.Response` object with data of type None
|
400
|
+
:rtype: :class:`~oci.response.Response`
|
401
|
+
|
402
|
+
:example:
|
403
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/cascading_delete_security_attribute_namespace.py.html>`__ to see an example of how to use cascading_delete_security_attribute_namespace API.
|
404
|
+
"""
|
405
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
406
|
+
required_arguments = ['securityAttributeNamespaceId']
|
407
|
+
resource_path = "/securityAttributeNamespaces/{securityAttributeNamespaceId}/actions/cascadeDelete"
|
408
|
+
method = "POST"
|
409
|
+
operation_name = "cascading_delete_security_attribute_namespace"
|
410
|
+
api_reference_link = ""
|
411
|
+
|
412
|
+
# Don't accept unknown kwargs
|
413
|
+
expected_kwargs = [
|
414
|
+
"allow_control_chars",
|
415
|
+
"retry_strategy",
|
416
|
+
"if_match",
|
417
|
+
"opc_request_id",
|
418
|
+
"opc_retry_token"
|
419
|
+
]
|
420
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
421
|
+
if extra_kwargs:
|
422
|
+
raise ValueError(
|
423
|
+
f"cascading_delete_security_attribute_namespace got unknown kwargs: {extra_kwargs!r}")
|
424
|
+
|
425
|
+
path_params = {
|
426
|
+
"securityAttributeNamespaceId": security_attribute_namespace_id
|
427
|
+
}
|
428
|
+
|
429
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
430
|
+
|
431
|
+
for (k, v) in six.iteritems(path_params):
|
432
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
433
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
434
|
+
|
435
|
+
header_params = {
|
436
|
+
"accept": "application/json",
|
437
|
+
"content-type": "application/json",
|
438
|
+
"if-match": kwargs.get("if_match", missing),
|
439
|
+
"opc-request-id": kwargs.get("opc_request_id", missing),
|
440
|
+
"opc-retry-token": kwargs.get("opc_retry_token", missing)
|
441
|
+
}
|
442
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
443
|
+
|
444
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
445
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
446
|
+
client_retry_strategy=self.retry_strategy
|
447
|
+
)
|
448
|
+
if retry_strategy is None:
|
449
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
450
|
+
|
451
|
+
if retry_strategy:
|
452
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
453
|
+
self.base_client.add_opc_retry_token_if_needed(header_params)
|
454
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
455
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
456
|
+
return retry_strategy.make_retrying_call(
|
457
|
+
self.base_client.call_api,
|
458
|
+
resource_path=resource_path,
|
459
|
+
method=method,
|
460
|
+
path_params=path_params,
|
461
|
+
header_params=header_params,
|
462
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
463
|
+
operation_name=operation_name,
|
464
|
+
api_reference_link=api_reference_link,
|
465
|
+
required_arguments=required_arguments)
|
466
|
+
else:
|
467
|
+
return self.base_client.call_api(
|
468
|
+
resource_path=resource_path,
|
469
|
+
method=method,
|
470
|
+
path_params=path_params,
|
471
|
+
header_params=header_params,
|
472
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
473
|
+
operation_name=operation_name,
|
474
|
+
api_reference_link=api_reference_link,
|
475
|
+
required_arguments=required_arguments)
|
476
|
+
|
477
|
+
def change_security_attribute_namespace_compartment(self, security_attribute_namespace_id, change_security_attribute_namespace_compartment_details, **kwargs):
|
478
|
+
"""
|
479
|
+
Moves the specified security attribute namespace to the specified compartment within the same tenancy.
|
480
|
+
|
481
|
+
To move the security attribute namespace, you must have the manage security-attributes permission on both compartments.
|
482
|
+
For more information about IAM policies, see `Details for IAM`__.
|
483
|
+
|
484
|
+
Moving a security attribute namespace moves all the security attributes contained in the security attribute namespace.
|
485
|
+
|
486
|
+
__ https://docs.cloud.oracle.com/Content/Identity/policyreference/iampolicyreference.htm
|
487
|
+
|
488
|
+
|
489
|
+
:param str security_attribute_namespace_id: (required)
|
490
|
+
The OCID of the security attribute namespace.
|
491
|
+
|
492
|
+
:param oci.security_attribute.models.ChangeSecurityAttributeNamespaceCompartmentDetails change_security_attribute_namespace_compartment_details: (required)
|
493
|
+
Request object for changing the compartment of a security attribute namespace.
|
494
|
+
|
495
|
+
:param str opc_retry_token: (optional)
|
496
|
+
A token that uniquely identifies a request so it can be retried in case of a timeout or
|
497
|
+
server error without risk of running that same action again. Retry tokens expire after 24
|
498
|
+
hours, but can be invalidated before then due to conflicting operations. For example, if a resource
|
499
|
+
has been deleted and removed from the system, then a retry of the original creation request
|
500
|
+
might be rejected.
|
501
|
+
|
502
|
+
:param str if_match: (optional)
|
503
|
+
For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
|
504
|
+
`if-match` parameter to the value of the etag from a previous GET or POST response for
|
505
|
+
that resource. The resource will be updated or deleted only if the etag you provide
|
506
|
+
matches the resource's current etag value.
|
507
|
+
|
508
|
+
:param str opc_request_id: (optional)
|
509
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
510
|
+
Oracle about a particular request, please provide the request ID.
|
511
|
+
The only valid characters for request IDs are letters, numbers,
|
512
|
+
underscore, and dash.
|
513
|
+
|
514
|
+
:param obj retry_strategy: (optional)
|
515
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
516
|
+
|
517
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
518
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
519
|
+
|
520
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
521
|
+
|
522
|
+
:param bool allow_control_chars: (optional)
|
523
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
524
|
+
By default, the response will not allow control characters in strings
|
525
|
+
|
526
|
+
:return: A :class:`~oci.response.Response` object with data of type None
|
527
|
+
:rtype: :class:`~oci.response.Response`
|
528
|
+
|
529
|
+
:example:
|
530
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/change_security_attribute_namespace_compartment.py.html>`__ to see an example of how to use change_security_attribute_namespace_compartment API.
|
531
|
+
"""
|
532
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
533
|
+
required_arguments = ['securityAttributeNamespaceId']
|
534
|
+
resource_path = "/securityAttributeNamespaces/{securityAttributeNamespaceId}/actions/changeCompartment"
|
535
|
+
method = "POST"
|
536
|
+
operation_name = "change_security_attribute_namespace_compartment"
|
537
|
+
api_reference_link = ""
|
538
|
+
|
539
|
+
# Don't accept unknown kwargs
|
540
|
+
expected_kwargs = [
|
541
|
+
"allow_control_chars",
|
542
|
+
"retry_strategy",
|
543
|
+
"opc_retry_token",
|
544
|
+
"if_match",
|
545
|
+
"opc_request_id"
|
546
|
+
]
|
547
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
548
|
+
if extra_kwargs:
|
549
|
+
raise ValueError(
|
550
|
+
f"change_security_attribute_namespace_compartment got unknown kwargs: {extra_kwargs!r}")
|
551
|
+
|
552
|
+
path_params = {
|
553
|
+
"securityAttributeNamespaceId": security_attribute_namespace_id
|
554
|
+
}
|
555
|
+
|
556
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
557
|
+
|
558
|
+
for (k, v) in six.iteritems(path_params):
|
559
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
560
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
561
|
+
|
562
|
+
header_params = {
|
563
|
+
"accept": "application/json",
|
564
|
+
"content-type": "application/json",
|
565
|
+
"opc-retry-token": kwargs.get("opc_retry_token", missing),
|
566
|
+
"if-match": kwargs.get("if_match", missing),
|
567
|
+
"opc-request-id": kwargs.get("opc_request_id", missing)
|
568
|
+
}
|
569
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
570
|
+
|
571
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
572
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
573
|
+
client_retry_strategy=self.retry_strategy
|
574
|
+
)
|
575
|
+
if retry_strategy is None:
|
576
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
577
|
+
|
578
|
+
if retry_strategy:
|
579
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
580
|
+
self.base_client.add_opc_retry_token_if_needed(header_params)
|
581
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
582
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
583
|
+
return retry_strategy.make_retrying_call(
|
584
|
+
self.base_client.call_api,
|
585
|
+
resource_path=resource_path,
|
586
|
+
method=method,
|
587
|
+
path_params=path_params,
|
588
|
+
header_params=header_params,
|
589
|
+
body=change_security_attribute_namespace_compartment_details,
|
590
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
591
|
+
operation_name=operation_name,
|
592
|
+
api_reference_link=api_reference_link,
|
593
|
+
required_arguments=required_arguments)
|
594
|
+
else:
|
595
|
+
return self.base_client.call_api(
|
596
|
+
resource_path=resource_path,
|
597
|
+
method=method,
|
598
|
+
path_params=path_params,
|
599
|
+
header_params=header_params,
|
600
|
+
body=change_security_attribute_namespace_compartment_details,
|
601
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
602
|
+
operation_name=operation_name,
|
603
|
+
api_reference_link=api_reference_link,
|
604
|
+
required_arguments=required_arguments)
|
605
|
+
|
606
|
+
def create_security_attribute(self, security_attribute_namespace_id, create_security_attribute_details, **kwargs):
|
607
|
+
"""
|
608
|
+
Creates a new security attribute in the specified security attribute namespace.
|
609
|
+
|
610
|
+
The security attribute requires either the OCID or the name of the security attribute namespace that will contain this
|
611
|
+
security attribute.
|
612
|
+
|
613
|
+
You must specify a *name* for the attribute, which must be unique across all attributes in the security attribute namespace
|
614
|
+
and cannot be changed. The only valid characters for security attribute names are:\u00A00-9, A-Z, a-z, -, _ characters.
|
615
|
+
Names are case insensitive. That means, for example, \"mySecurityAttribute\" and \"mysecurityattribute\" are not allowed in the same namespace.
|
616
|
+
If you specify a name that's already in use in the security attribute namespace, a 409 error is returned.
|
617
|
+
|
618
|
+
The security attribute must have a *description*. It does not have to be unique, and you can change it with
|
619
|
+
:func:`update_security_attribute`.
|
620
|
+
|
621
|
+
The security attribute must have a value type, which is specified with a validator. Security attribute can use either a
|
622
|
+
static value or a list of possible values. Static values are entered by a user applying the security attribute
|
623
|
+
to a resource. Lists are created by the user and the user must apply a value from the list. Lists
|
624
|
+
are validated.
|
625
|
+
|
626
|
+
|
627
|
+
:param str security_attribute_namespace_id: (required)
|
628
|
+
The OCID of the security attribute namespace.
|
629
|
+
|
630
|
+
:param oci.security_attribute.models.CreateSecurityAttributeDetails create_security_attribute_details: (required)
|
631
|
+
Request object for creating a new security attribute in the specified security attribute namespace.
|
632
|
+
|
633
|
+
:param str opc_request_id: (optional)
|
634
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
635
|
+
Oracle about a particular request, please provide the request ID.
|
636
|
+
The only valid characters for request IDs are letters, numbers,
|
637
|
+
underscore, and dash.
|
638
|
+
|
639
|
+
:param str opc_retry_token: (optional)
|
640
|
+
A token that uniquely identifies a request so it can be retried in case of a timeout or
|
641
|
+
server error without risk of running that same action again. Retry tokens expire after 24
|
642
|
+
hours, but can be invalidated before then due to conflicting operations. For example, if a resource
|
643
|
+
has been deleted and removed from the system, then a retry of the original creation request
|
644
|
+
might be rejected.
|
645
|
+
|
646
|
+
:param obj retry_strategy: (optional)
|
647
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
648
|
+
|
649
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
650
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
651
|
+
|
652
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
653
|
+
|
654
|
+
:param bool allow_control_chars: (optional)
|
655
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
656
|
+
By default, the response will not allow control characters in strings
|
657
|
+
|
658
|
+
:return: A :class:`~oci.response.Response` object with data of type :class:`~oci.security_attribute.models.SecurityAttribute`
|
659
|
+
:rtype: :class:`~oci.response.Response`
|
660
|
+
|
661
|
+
:example:
|
662
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/create_security_attribute.py.html>`__ to see an example of how to use create_security_attribute API.
|
663
|
+
"""
|
664
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
665
|
+
required_arguments = ['securityAttributeNamespaceId']
|
666
|
+
resource_path = "/securityAttributeNamespaces/{securityAttributeNamespaceId}/securityAttributes"
|
667
|
+
method = "POST"
|
668
|
+
operation_name = "create_security_attribute"
|
669
|
+
api_reference_link = ""
|
670
|
+
|
671
|
+
# Don't accept unknown kwargs
|
672
|
+
expected_kwargs = [
|
673
|
+
"allow_control_chars",
|
674
|
+
"retry_strategy",
|
675
|
+
"opc_request_id",
|
676
|
+
"opc_retry_token"
|
677
|
+
]
|
678
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
679
|
+
if extra_kwargs:
|
680
|
+
raise ValueError(
|
681
|
+
f"create_security_attribute got unknown kwargs: {extra_kwargs!r}")
|
682
|
+
|
683
|
+
path_params = {
|
684
|
+
"securityAttributeNamespaceId": security_attribute_namespace_id
|
685
|
+
}
|
686
|
+
|
687
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
688
|
+
|
689
|
+
for (k, v) in six.iteritems(path_params):
|
690
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
691
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
692
|
+
|
693
|
+
header_params = {
|
694
|
+
"accept": "application/json",
|
695
|
+
"content-type": "application/json",
|
696
|
+
"opc-request-id": kwargs.get("opc_request_id", missing),
|
697
|
+
"opc-retry-token": kwargs.get("opc_retry_token", missing)
|
698
|
+
}
|
699
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
700
|
+
|
701
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
702
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
703
|
+
client_retry_strategy=self.retry_strategy
|
704
|
+
)
|
705
|
+
if retry_strategy is None:
|
706
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
707
|
+
|
708
|
+
if retry_strategy:
|
709
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
710
|
+
self.base_client.add_opc_retry_token_if_needed(header_params)
|
711
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
712
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
713
|
+
return retry_strategy.make_retrying_call(
|
714
|
+
self.base_client.call_api,
|
715
|
+
resource_path=resource_path,
|
716
|
+
method=method,
|
717
|
+
path_params=path_params,
|
718
|
+
header_params=header_params,
|
719
|
+
body=create_security_attribute_details,
|
720
|
+
response_type="SecurityAttribute",
|
721
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
722
|
+
operation_name=operation_name,
|
723
|
+
api_reference_link=api_reference_link,
|
724
|
+
required_arguments=required_arguments)
|
725
|
+
else:
|
726
|
+
return self.base_client.call_api(
|
727
|
+
resource_path=resource_path,
|
728
|
+
method=method,
|
729
|
+
path_params=path_params,
|
730
|
+
header_params=header_params,
|
731
|
+
body=create_security_attribute_details,
|
732
|
+
response_type="SecurityAttribute",
|
733
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
734
|
+
operation_name=operation_name,
|
735
|
+
api_reference_link=api_reference_link,
|
736
|
+
required_arguments=required_arguments)
|
737
|
+
|
738
|
+
def create_security_attribute_namespace(self, create_security_attribute_namespace_details, **kwargs):
|
739
|
+
"""
|
740
|
+
Creates a new security attribute namespace in the specified compartment.
|
741
|
+
|
742
|
+
You must specify the compartment ID in the request object (remember that the tenancy is simply the root
|
743
|
+
compartment).
|
744
|
+
|
745
|
+
You must also specify a *name* for the namespace, which must be unique across all namespaces in your tenancy
|
746
|
+
and cannot be changed. The only valid characters for security attribute names are: \u00A00-9, A-Z, a-z, -, _ characters.
|
747
|
+
Names are case insensitive. That means, for example, \"myNamespace\" and \"mynamespace\" are not allowed
|
748
|
+
in the same tenancy. Once you created a namespace, you cannot change the name.
|
749
|
+
If you specify a name that's already in use in the tenancy, a 409 error is returned.
|
750
|
+
|
751
|
+
You must also specify a *description* for the namespace.
|
752
|
+
It does not have to be unique, and you can change it with
|
753
|
+
:func:`security_attribute_namespace`.
|
754
|
+
|
755
|
+
|
756
|
+
:param oci.security_attribute.models.CreateSecurityAttributeNamespaceDetails create_security_attribute_namespace_details: (required)
|
757
|
+
Request object for creating a new security attribute namespace.
|
758
|
+
|
759
|
+
:param str opc_retry_token: (optional)
|
760
|
+
A token that uniquely identifies a request so it can be retried in case of a timeout or
|
761
|
+
server error without risk of running that same action again. Retry tokens expire after 24
|
762
|
+
hours, but can be invalidated before then due to conflicting operations. For example, if a resource
|
763
|
+
has been deleted and removed from the system, then a retry of the original creation request
|
764
|
+
might be rejected.
|
765
|
+
|
766
|
+
:param str opc_request_id: (optional)
|
767
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
768
|
+
Oracle about a particular request, please provide the request ID.
|
769
|
+
The only valid characters for request IDs are letters, numbers,
|
770
|
+
underscore, and dash.
|
771
|
+
|
772
|
+
:param obj retry_strategy: (optional)
|
773
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
774
|
+
|
775
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
776
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
777
|
+
|
778
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
779
|
+
|
780
|
+
:param bool allow_control_chars: (optional)
|
781
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
782
|
+
By default, the response will not allow control characters in strings
|
783
|
+
|
784
|
+
:return: A :class:`~oci.response.Response` object with data of type :class:`~oci.security_attribute.models.SecurityAttributeNamespace`
|
785
|
+
:rtype: :class:`~oci.response.Response`
|
786
|
+
|
787
|
+
:example:
|
788
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/create_security_attribute_namespace.py.html>`__ to see an example of how to use create_security_attribute_namespace API.
|
789
|
+
"""
|
790
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
791
|
+
required_arguments = []
|
792
|
+
resource_path = "/securityAttributeNamespaces"
|
793
|
+
method = "POST"
|
794
|
+
operation_name = "create_security_attribute_namespace"
|
795
|
+
api_reference_link = ""
|
796
|
+
|
797
|
+
# Don't accept unknown kwargs
|
798
|
+
expected_kwargs = [
|
799
|
+
"allow_control_chars",
|
800
|
+
"retry_strategy",
|
801
|
+
"opc_retry_token",
|
802
|
+
"opc_request_id"
|
803
|
+
]
|
804
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
805
|
+
if extra_kwargs:
|
806
|
+
raise ValueError(
|
807
|
+
f"create_security_attribute_namespace got unknown kwargs: {extra_kwargs!r}")
|
808
|
+
|
809
|
+
header_params = {
|
810
|
+
"accept": "application/json",
|
811
|
+
"content-type": "application/json",
|
812
|
+
"opc-retry-token": kwargs.get("opc_retry_token", missing),
|
813
|
+
"opc-request-id": kwargs.get("opc_request_id", missing)
|
814
|
+
}
|
815
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
816
|
+
|
817
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
818
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
819
|
+
client_retry_strategy=self.retry_strategy
|
820
|
+
)
|
821
|
+
if retry_strategy is None:
|
822
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
823
|
+
|
824
|
+
if retry_strategy:
|
825
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
826
|
+
self.base_client.add_opc_retry_token_if_needed(header_params)
|
827
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
828
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
829
|
+
return retry_strategy.make_retrying_call(
|
830
|
+
self.base_client.call_api,
|
831
|
+
resource_path=resource_path,
|
832
|
+
method=method,
|
833
|
+
header_params=header_params,
|
834
|
+
body=create_security_attribute_namespace_details,
|
835
|
+
response_type="SecurityAttributeNamespace",
|
836
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
837
|
+
operation_name=operation_name,
|
838
|
+
api_reference_link=api_reference_link,
|
839
|
+
required_arguments=required_arguments)
|
840
|
+
else:
|
841
|
+
return self.base_client.call_api(
|
842
|
+
resource_path=resource_path,
|
843
|
+
method=method,
|
844
|
+
header_params=header_params,
|
845
|
+
body=create_security_attribute_namespace_details,
|
846
|
+
response_type="SecurityAttributeNamespace",
|
847
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
848
|
+
operation_name=operation_name,
|
849
|
+
api_reference_link=api_reference_link,
|
850
|
+
required_arguments=required_arguments)
|
851
|
+
|
852
|
+
def delete_security_attribute(self, security_attribute_namespace_id, security_attribute_name, **kwargs):
|
853
|
+
"""
|
854
|
+
Deletes the specified security attribute. This operation triggers a process that removes the
|
855
|
+
security attribute from all resources in your tenancy.
|
856
|
+
|
857
|
+
When you start the delete operation, the state of the security attribute changes to DELETING and security attribute removal
|
858
|
+
from resources begins. This can take up to 48 hours depending on the number of resources that
|
859
|
+
were tagged as well as the regions in which those resources reside.
|
860
|
+
|
861
|
+
When all attributes have been removed, the state changes to DELETED. You cannot restore a deleted attribute. Once the deleted attribute
|
862
|
+
changes its state to DELETED, you can use the same security attribute name again.
|
863
|
+
|
864
|
+
After you start this operation, you cannot start either the :func:`bulk_delete_security_attributes` or the :func:`cascade_delete_tag_namespace` operation until this process completes.
|
865
|
+
|
866
|
+
To delete a security attribute, you must first retire it. Use :func:`update_security_attribute`
|
867
|
+
to retire a security attribute.
|
868
|
+
|
869
|
+
|
870
|
+
:param str security_attribute_namespace_id: (required)
|
871
|
+
The OCID of the security attribute namespace.
|
872
|
+
|
873
|
+
:param str security_attribute_name: (required)
|
874
|
+
The name of the security attribute.
|
875
|
+
|
876
|
+
:param str if_match: (optional)
|
877
|
+
For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
|
878
|
+
`if-match` parameter to the value of the etag from a previous GET or POST response for
|
879
|
+
that resource. The resource will be updated or deleted only if the etag you provide
|
880
|
+
matches the resource's current etag value.
|
881
|
+
|
882
|
+
:param str opc_request_id: (optional)
|
883
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
884
|
+
Oracle about a particular request, please provide the request ID.
|
885
|
+
The only valid characters for request IDs are letters, numbers,
|
886
|
+
underscore, and dash.
|
887
|
+
|
888
|
+
:param str opc_retry_token: (optional)
|
889
|
+
A token that uniquely identifies a request so it can be retried in case of a timeout or
|
890
|
+
server error without risk of running that same action again. Retry tokens expire after 24
|
891
|
+
hours, but can be invalidated before then due to conflicting operations. For example, if a resource
|
892
|
+
has been deleted and removed from the system, then a retry of the original creation request
|
893
|
+
might be rejected.
|
894
|
+
|
895
|
+
:param obj retry_strategy: (optional)
|
896
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
897
|
+
|
898
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
899
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
900
|
+
|
901
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
902
|
+
|
903
|
+
:param bool allow_control_chars: (optional)
|
904
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
905
|
+
By default, the response will not allow control characters in strings
|
906
|
+
|
907
|
+
:return: A :class:`~oci.response.Response` object with data of type None
|
908
|
+
:rtype: :class:`~oci.response.Response`
|
909
|
+
|
910
|
+
:example:
|
911
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/delete_security_attribute.py.html>`__ to see an example of how to use delete_security_attribute API.
|
912
|
+
"""
|
913
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
914
|
+
required_arguments = ['securityAttributeNamespaceId', 'securityAttributeName']
|
915
|
+
resource_path = "/securityAttributeNamespaces/{securityAttributeNamespaceId}/securityAttributes/{securityAttributeName}"
|
916
|
+
method = "DELETE"
|
917
|
+
operation_name = "delete_security_attribute"
|
918
|
+
api_reference_link = ""
|
919
|
+
|
920
|
+
# Don't accept unknown kwargs
|
921
|
+
expected_kwargs = [
|
922
|
+
"allow_control_chars",
|
923
|
+
"retry_strategy",
|
924
|
+
"if_match",
|
925
|
+
"opc_request_id",
|
926
|
+
"opc_retry_token"
|
927
|
+
]
|
928
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
929
|
+
if extra_kwargs:
|
930
|
+
raise ValueError(
|
931
|
+
f"delete_security_attribute got unknown kwargs: {extra_kwargs!r}")
|
932
|
+
|
933
|
+
path_params = {
|
934
|
+
"securityAttributeNamespaceId": security_attribute_namespace_id,
|
935
|
+
"securityAttributeName": security_attribute_name
|
936
|
+
}
|
937
|
+
|
938
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
939
|
+
|
940
|
+
for (k, v) in six.iteritems(path_params):
|
941
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
942
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
943
|
+
|
944
|
+
header_params = {
|
945
|
+
"accept": "application/json",
|
946
|
+
"content-type": "application/json",
|
947
|
+
"if-match": kwargs.get("if_match", missing),
|
948
|
+
"opc-request-id": kwargs.get("opc_request_id", missing),
|
949
|
+
"opc-retry-token": kwargs.get("opc_retry_token", missing)
|
950
|
+
}
|
951
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
952
|
+
|
953
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
954
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
955
|
+
client_retry_strategy=self.retry_strategy
|
956
|
+
)
|
957
|
+
if retry_strategy is None:
|
958
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
959
|
+
|
960
|
+
if retry_strategy:
|
961
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
962
|
+
self.base_client.add_opc_retry_token_if_needed(header_params)
|
963
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
964
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
965
|
+
return retry_strategy.make_retrying_call(
|
966
|
+
self.base_client.call_api,
|
967
|
+
resource_path=resource_path,
|
968
|
+
method=method,
|
969
|
+
path_params=path_params,
|
970
|
+
header_params=header_params,
|
971
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
972
|
+
operation_name=operation_name,
|
973
|
+
api_reference_link=api_reference_link,
|
974
|
+
required_arguments=required_arguments)
|
975
|
+
else:
|
976
|
+
return self.base_client.call_api(
|
977
|
+
resource_path=resource_path,
|
978
|
+
method=method,
|
979
|
+
path_params=path_params,
|
980
|
+
header_params=header_params,
|
981
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
982
|
+
operation_name=operation_name,
|
983
|
+
api_reference_link=api_reference_link,
|
984
|
+
required_arguments=required_arguments)
|
985
|
+
|
986
|
+
def delete_security_attribute_namespace(self, security_attribute_namespace_id, **kwargs):
|
987
|
+
"""
|
988
|
+
Deletes the specified security attribute namespace. Only an empty security attribute namespace can be deleted with this operation. To use this operation
|
989
|
+
to delete a security attribute namespace that contains security attributes, first delete all of its security attributes.
|
990
|
+
Use :func:`delete_security_attribute` to delete a security attribute.
|
991
|
+
|
992
|
+
|
993
|
+
:param str security_attribute_namespace_id: (required)
|
994
|
+
The OCID of the security attribute namespace.
|
995
|
+
|
996
|
+
:param str if_match: (optional)
|
997
|
+
For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
|
998
|
+
`if-match` parameter to the value of the etag from a previous GET or POST response for
|
999
|
+
that resource. The resource will be updated or deleted only if the etag you provide
|
1000
|
+
matches the resource's current etag value.
|
1001
|
+
|
1002
|
+
:param str opc_request_id: (optional)
|
1003
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
1004
|
+
Oracle about a particular request, please provide the request ID.
|
1005
|
+
The only valid characters for request IDs are letters, numbers,
|
1006
|
+
underscore, and dash.
|
1007
|
+
|
1008
|
+
:param str opc_retry_token: (optional)
|
1009
|
+
A token that uniquely identifies a request so it can be retried in case of a timeout or
|
1010
|
+
server error without risk of running that same action again. Retry tokens expire after 24
|
1011
|
+
hours, but can be invalidated before then due to conflicting operations. For example, if a resource
|
1012
|
+
has been deleted and removed from the system, then a retry of the original creation request
|
1013
|
+
might be rejected.
|
1014
|
+
|
1015
|
+
:param obj retry_strategy: (optional)
|
1016
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
1017
|
+
|
1018
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
1019
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
1020
|
+
|
1021
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
1022
|
+
|
1023
|
+
:param bool allow_control_chars: (optional)
|
1024
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
1025
|
+
By default, the response will not allow control characters in strings
|
1026
|
+
|
1027
|
+
:return: A :class:`~oci.response.Response` object with data of type None
|
1028
|
+
:rtype: :class:`~oci.response.Response`
|
1029
|
+
|
1030
|
+
:example:
|
1031
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/delete_security_attribute_namespace.py.html>`__ to see an example of how to use delete_security_attribute_namespace API.
|
1032
|
+
"""
|
1033
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
1034
|
+
required_arguments = ['securityAttributeNamespaceId']
|
1035
|
+
resource_path = "/securityAttributeNamespaces/{securityAttributeNamespaceId}"
|
1036
|
+
method = "DELETE"
|
1037
|
+
operation_name = "delete_security_attribute_namespace"
|
1038
|
+
api_reference_link = ""
|
1039
|
+
|
1040
|
+
# Don't accept unknown kwargs
|
1041
|
+
expected_kwargs = [
|
1042
|
+
"allow_control_chars",
|
1043
|
+
"retry_strategy",
|
1044
|
+
"if_match",
|
1045
|
+
"opc_request_id",
|
1046
|
+
"opc_retry_token"
|
1047
|
+
]
|
1048
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
1049
|
+
if extra_kwargs:
|
1050
|
+
raise ValueError(
|
1051
|
+
f"delete_security_attribute_namespace got unknown kwargs: {extra_kwargs!r}")
|
1052
|
+
|
1053
|
+
path_params = {
|
1054
|
+
"securityAttributeNamespaceId": security_attribute_namespace_id
|
1055
|
+
}
|
1056
|
+
|
1057
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
1058
|
+
|
1059
|
+
for (k, v) in six.iteritems(path_params):
|
1060
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
1061
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
1062
|
+
|
1063
|
+
header_params = {
|
1064
|
+
"accept": "application/json",
|
1065
|
+
"content-type": "application/json",
|
1066
|
+
"if-match": kwargs.get("if_match", missing),
|
1067
|
+
"opc-request-id": kwargs.get("opc_request_id", missing),
|
1068
|
+
"opc-retry-token": kwargs.get("opc_retry_token", missing)
|
1069
|
+
}
|
1070
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
1071
|
+
|
1072
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
1073
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
1074
|
+
client_retry_strategy=self.retry_strategy
|
1075
|
+
)
|
1076
|
+
if retry_strategy is None:
|
1077
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
1078
|
+
|
1079
|
+
if retry_strategy:
|
1080
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
1081
|
+
self.base_client.add_opc_retry_token_if_needed(header_params)
|
1082
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
1083
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
1084
|
+
return retry_strategy.make_retrying_call(
|
1085
|
+
self.base_client.call_api,
|
1086
|
+
resource_path=resource_path,
|
1087
|
+
method=method,
|
1088
|
+
path_params=path_params,
|
1089
|
+
header_params=header_params,
|
1090
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1091
|
+
operation_name=operation_name,
|
1092
|
+
api_reference_link=api_reference_link,
|
1093
|
+
required_arguments=required_arguments)
|
1094
|
+
else:
|
1095
|
+
return self.base_client.call_api(
|
1096
|
+
resource_path=resource_path,
|
1097
|
+
method=method,
|
1098
|
+
path_params=path_params,
|
1099
|
+
header_params=header_params,
|
1100
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1101
|
+
operation_name=operation_name,
|
1102
|
+
api_reference_link=api_reference_link,
|
1103
|
+
required_arguments=required_arguments)
|
1104
|
+
|
1105
|
+
def get_security_attribute(self, security_attribute_namespace_id, security_attribute_name, **kwargs):
|
1106
|
+
"""
|
1107
|
+
Gets the specified security attribute's information.
|
1108
|
+
|
1109
|
+
|
1110
|
+
:param str security_attribute_namespace_id: (required)
|
1111
|
+
The OCID of the security attribute namespace.
|
1112
|
+
|
1113
|
+
:param str security_attribute_name: (required)
|
1114
|
+
The name of the security attribute.
|
1115
|
+
|
1116
|
+
:param str opc_request_id: (optional)
|
1117
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
1118
|
+
Oracle about a particular request, please provide the request ID.
|
1119
|
+
The only valid characters for request IDs are letters, numbers,
|
1120
|
+
underscore, and dash.
|
1121
|
+
|
1122
|
+
:param obj retry_strategy: (optional)
|
1123
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
1124
|
+
|
1125
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
1126
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
1127
|
+
|
1128
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
1129
|
+
|
1130
|
+
:param bool allow_control_chars: (optional)
|
1131
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
1132
|
+
By default, the response will not allow control characters in strings
|
1133
|
+
|
1134
|
+
:return: A :class:`~oci.response.Response` object with data of type :class:`~oci.security_attribute.models.SecurityAttribute`
|
1135
|
+
:rtype: :class:`~oci.response.Response`
|
1136
|
+
|
1137
|
+
:example:
|
1138
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/get_security_attribute.py.html>`__ to see an example of how to use get_security_attribute API.
|
1139
|
+
"""
|
1140
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
1141
|
+
required_arguments = ['securityAttributeNamespaceId', 'securityAttributeName']
|
1142
|
+
resource_path = "/securityAttributeNamespaces/{securityAttributeNamespaceId}/securityAttributes/{securityAttributeName}"
|
1143
|
+
method = "GET"
|
1144
|
+
operation_name = "get_security_attribute"
|
1145
|
+
api_reference_link = ""
|
1146
|
+
|
1147
|
+
# Don't accept unknown kwargs
|
1148
|
+
expected_kwargs = [
|
1149
|
+
"allow_control_chars",
|
1150
|
+
"retry_strategy",
|
1151
|
+
"opc_request_id"
|
1152
|
+
]
|
1153
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
1154
|
+
if extra_kwargs:
|
1155
|
+
raise ValueError(
|
1156
|
+
f"get_security_attribute got unknown kwargs: {extra_kwargs!r}")
|
1157
|
+
|
1158
|
+
path_params = {
|
1159
|
+
"securityAttributeNamespaceId": security_attribute_namespace_id,
|
1160
|
+
"securityAttributeName": security_attribute_name
|
1161
|
+
}
|
1162
|
+
|
1163
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
1164
|
+
|
1165
|
+
for (k, v) in six.iteritems(path_params):
|
1166
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
1167
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
1168
|
+
|
1169
|
+
header_params = {
|
1170
|
+
"accept": "application/json",
|
1171
|
+
"content-type": "application/json",
|
1172
|
+
"opc-request-id": kwargs.get("opc_request_id", missing)
|
1173
|
+
}
|
1174
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
1175
|
+
|
1176
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
1177
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
1178
|
+
client_retry_strategy=self.retry_strategy
|
1179
|
+
)
|
1180
|
+
if retry_strategy is None:
|
1181
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
1182
|
+
|
1183
|
+
if retry_strategy:
|
1184
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
1185
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
1186
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
1187
|
+
return retry_strategy.make_retrying_call(
|
1188
|
+
self.base_client.call_api,
|
1189
|
+
resource_path=resource_path,
|
1190
|
+
method=method,
|
1191
|
+
path_params=path_params,
|
1192
|
+
header_params=header_params,
|
1193
|
+
response_type="SecurityAttribute",
|
1194
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1195
|
+
operation_name=operation_name,
|
1196
|
+
api_reference_link=api_reference_link,
|
1197
|
+
required_arguments=required_arguments)
|
1198
|
+
else:
|
1199
|
+
return self.base_client.call_api(
|
1200
|
+
resource_path=resource_path,
|
1201
|
+
method=method,
|
1202
|
+
path_params=path_params,
|
1203
|
+
header_params=header_params,
|
1204
|
+
response_type="SecurityAttribute",
|
1205
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1206
|
+
operation_name=operation_name,
|
1207
|
+
api_reference_link=api_reference_link,
|
1208
|
+
required_arguments=required_arguments)
|
1209
|
+
|
1210
|
+
def get_security_attribute_namespace(self, security_attribute_namespace_id, **kwargs):
|
1211
|
+
"""
|
1212
|
+
Gets the specified security attribute namespace's information.
|
1213
|
+
|
1214
|
+
|
1215
|
+
:param str security_attribute_namespace_id: (required)
|
1216
|
+
The OCID of the security attribute namespace.
|
1217
|
+
|
1218
|
+
:param str opc_request_id: (optional)
|
1219
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
1220
|
+
Oracle about a particular request, please provide the request ID.
|
1221
|
+
The only valid characters for request IDs are letters, numbers,
|
1222
|
+
underscore, and dash.
|
1223
|
+
|
1224
|
+
:param obj retry_strategy: (optional)
|
1225
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
1226
|
+
|
1227
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
1228
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
1229
|
+
|
1230
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
1231
|
+
|
1232
|
+
:param bool allow_control_chars: (optional)
|
1233
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
1234
|
+
By default, the response will not allow control characters in strings
|
1235
|
+
|
1236
|
+
:return: A :class:`~oci.response.Response` object with data of type :class:`~oci.security_attribute.models.SecurityAttributeNamespace`
|
1237
|
+
:rtype: :class:`~oci.response.Response`
|
1238
|
+
|
1239
|
+
:example:
|
1240
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/get_security_attribute_namespace.py.html>`__ to see an example of how to use get_security_attribute_namespace API.
|
1241
|
+
"""
|
1242
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
1243
|
+
required_arguments = ['securityAttributeNamespaceId']
|
1244
|
+
resource_path = "/securityAttributeNamespaces/{securityAttributeNamespaceId}"
|
1245
|
+
method = "GET"
|
1246
|
+
operation_name = "get_security_attribute_namespace"
|
1247
|
+
api_reference_link = ""
|
1248
|
+
|
1249
|
+
# Don't accept unknown kwargs
|
1250
|
+
expected_kwargs = [
|
1251
|
+
"allow_control_chars",
|
1252
|
+
"retry_strategy",
|
1253
|
+
"opc_request_id"
|
1254
|
+
]
|
1255
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
1256
|
+
if extra_kwargs:
|
1257
|
+
raise ValueError(
|
1258
|
+
f"get_security_attribute_namespace got unknown kwargs: {extra_kwargs!r}")
|
1259
|
+
|
1260
|
+
path_params = {
|
1261
|
+
"securityAttributeNamespaceId": security_attribute_namespace_id
|
1262
|
+
}
|
1263
|
+
|
1264
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
1265
|
+
|
1266
|
+
for (k, v) in six.iteritems(path_params):
|
1267
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
1268
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
1269
|
+
|
1270
|
+
header_params = {
|
1271
|
+
"accept": "application/json",
|
1272
|
+
"content-type": "application/json",
|
1273
|
+
"opc-request-id": kwargs.get("opc_request_id", missing)
|
1274
|
+
}
|
1275
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
1276
|
+
|
1277
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
1278
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
1279
|
+
client_retry_strategy=self.retry_strategy
|
1280
|
+
)
|
1281
|
+
if retry_strategy is None:
|
1282
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
1283
|
+
|
1284
|
+
if retry_strategy:
|
1285
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
1286
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
1287
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
1288
|
+
return retry_strategy.make_retrying_call(
|
1289
|
+
self.base_client.call_api,
|
1290
|
+
resource_path=resource_path,
|
1291
|
+
method=method,
|
1292
|
+
path_params=path_params,
|
1293
|
+
header_params=header_params,
|
1294
|
+
response_type="SecurityAttributeNamespace",
|
1295
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1296
|
+
operation_name=operation_name,
|
1297
|
+
api_reference_link=api_reference_link,
|
1298
|
+
required_arguments=required_arguments)
|
1299
|
+
else:
|
1300
|
+
return self.base_client.call_api(
|
1301
|
+
resource_path=resource_path,
|
1302
|
+
method=method,
|
1303
|
+
path_params=path_params,
|
1304
|
+
header_params=header_params,
|
1305
|
+
response_type="SecurityAttributeNamespace",
|
1306
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1307
|
+
operation_name=operation_name,
|
1308
|
+
api_reference_link=api_reference_link,
|
1309
|
+
required_arguments=required_arguments)
|
1310
|
+
|
1311
|
+
def get_security_attribute_work_request(self, work_request_id, **kwargs):
|
1312
|
+
"""
|
1313
|
+
Gets details on a specified work request. The workRequestID is returned in the opc-work-request-id header
|
1314
|
+
for any asynchronous operation in security attributes service.
|
1315
|
+
|
1316
|
+
|
1317
|
+
:param str work_request_id: (required)
|
1318
|
+
The OCID of the work request.
|
1319
|
+
|
1320
|
+
:param str opc_request_id: (optional)
|
1321
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
1322
|
+
Oracle about a particular request, please provide the request ID.
|
1323
|
+
The only valid characters for request IDs are letters, numbers,
|
1324
|
+
underscore, and dash.
|
1325
|
+
|
1326
|
+
:param obj retry_strategy: (optional)
|
1327
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
1328
|
+
|
1329
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
1330
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
1331
|
+
|
1332
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
1333
|
+
|
1334
|
+
:param bool allow_control_chars: (optional)
|
1335
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
1336
|
+
By default, the response will not allow control characters in strings
|
1337
|
+
|
1338
|
+
:return: A :class:`~oci.response.Response` object with data of type :class:`~oci.security_attribute.models.SecurityAttributeWorkRequest`
|
1339
|
+
:rtype: :class:`~oci.response.Response`
|
1340
|
+
|
1341
|
+
:example:
|
1342
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/get_security_attribute_work_request.py.html>`__ to see an example of how to use get_security_attribute_work_request API.
|
1343
|
+
"""
|
1344
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
1345
|
+
required_arguments = ['workRequestId']
|
1346
|
+
resource_path = "/securityAttributeWorkRequests/{workRequestId}"
|
1347
|
+
method = "GET"
|
1348
|
+
operation_name = "get_security_attribute_work_request"
|
1349
|
+
api_reference_link = ""
|
1350
|
+
|
1351
|
+
# Don't accept unknown kwargs
|
1352
|
+
expected_kwargs = [
|
1353
|
+
"allow_control_chars",
|
1354
|
+
"retry_strategy",
|
1355
|
+
"opc_request_id"
|
1356
|
+
]
|
1357
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
1358
|
+
if extra_kwargs:
|
1359
|
+
raise ValueError(
|
1360
|
+
f"get_security_attribute_work_request got unknown kwargs: {extra_kwargs!r}")
|
1361
|
+
|
1362
|
+
path_params = {
|
1363
|
+
"workRequestId": work_request_id
|
1364
|
+
}
|
1365
|
+
|
1366
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
1367
|
+
|
1368
|
+
for (k, v) in six.iteritems(path_params):
|
1369
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
1370
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
1371
|
+
|
1372
|
+
header_params = {
|
1373
|
+
"accept": "application/json",
|
1374
|
+
"content-type": "application/json",
|
1375
|
+
"opc-request-id": kwargs.get("opc_request_id", missing)
|
1376
|
+
}
|
1377
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
1378
|
+
|
1379
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
1380
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
1381
|
+
client_retry_strategy=self.retry_strategy
|
1382
|
+
)
|
1383
|
+
if retry_strategy is None:
|
1384
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
1385
|
+
|
1386
|
+
if retry_strategy:
|
1387
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
1388
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
1389
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
1390
|
+
return retry_strategy.make_retrying_call(
|
1391
|
+
self.base_client.call_api,
|
1392
|
+
resource_path=resource_path,
|
1393
|
+
method=method,
|
1394
|
+
path_params=path_params,
|
1395
|
+
header_params=header_params,
|
1396
|
+
response_type="SecurityAttributeWorkRequest",
|
1397
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1398
|
+
operation_name=operation_name,
|
1399
|
+
api_reference_link=api_reference_link,
|
1400
|
+
required_arguments=required_arguments)
|
1401
|
+
else:
|
1402
|
+
return self.base_client.call_api(
|
1403
|
+
resource_path=resource_path,
|
1404
|
+
method=method,
|
1405
|
+
path_params=path_params,
|
1406
|
+
header_params=header_params,
|
1407
|
+
response_type="SecurityAttributeWorkRequest",
|
1408
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1409
|
+
operation_name=operation_name,
|
1410
|
+
api_reference_link=api_reference_link,
|
1411
|
+
required_arguments=required_arguments)
|
1412
|
+
|
1413
|
+
def list_security_attribute_namespaces(self, **kwargs):
|
1414
|
+
"""
|
1415
|
+
Lists the security attribute namespaces in the specified compartment.
|
1416
|
+
|
1417
|
+
|
1418
|
+
:param str compartment_id: (optional)
|
1419
|
+
The `OCID`__ of the compartment in which to list resources.
|
1420
|
+
|
1421
|
+
__ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
|
1422
|
+
|
1423
|
+
:param str page: (optional)
|
1424
|
+
The value of the `opc-next-page` response header from the previous \"List\" call.
|
1425
|
+
|
1426
|
+
:param int limit: (optional)
|
1427
|
+
The maximum number of items to return in a paginated \"List\" call.
|
1428
|
+
|
1429
|
+
:param str sort_order: (optional)
|
1430
|
+
The sort order to use, either ascending (`ASC`) or descending (`DESC`).
|
1431
|
+
|
1432
|
+
Allowed values are: "ASC", "DESC"
|
1433
|
+
|
1434
|
+
:param str sort_by: (optional)
|
1435
|
+
The field to sort by. You can provide one sort order (`sortOrder`). Default order for
|
1436
|
+
TIMECREATED is descending. Default order for NAME is ascending. The NAME
|
1437
|
+
sort order is case sensitive.
|
1438
|
+
|
1439
|
+
**Note:** In general, some \"List\" operations (for example, `ListInstances`) let you
|
1440
|
+
optionally filter by Availability Domain if the scope of the resource type is within a
|
1441
|
+
single Availability Domain. If you call one of these \"List\" operations without specifying
|
1442
|
+
an Availability Domain, the resources are grouped by Availability Domain, then sorted.
|
1443
|
+
|
1444
|
+
Allowed values are: "TIMECREATED", "NAME"
|
1445
|
+
|
1446
|
+
:param str name: (optional)
|
1447
|
+
A filter to return only resources that match the entire display name given.
|
1448
|
+
|
1449
|
+
:param str opc_request_id: (optional)
|
1450
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
1451
|
+
Oracle about a particular request, please provide the request ID.
|
1452
|
+
The only valid characters for request IDs are letters, numbers,
|
1453
|
+
underscore, and dash.
|
1454
|
+
|
1455
|
+
:param bool compartment_id_in_subtree: (optional)
|
1456
|
+
An optional boolean parameter indicating whether to retrieve all security attribute namespaces in subcompartments. If this
|
1457
|
+
parameter is not specified, only the namespaces defined in the specified compartment are retrieved.
|
1458
|
+
|
1459
|
+
:param str lifecycle_state: (optional)
|
1460
|
+
A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
|
1461
|
+
|
1462
|
+
Allowed values are: "ACTIVE", "INACTIVE", "DELETING", "DELETED"
|
1463
|
+
|
1464
|
+
:param obj retry_strategy: (optional)
|
1465
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
1466
|
+
|
1467
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
1468
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
1469
|
+
|
1470
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
1471
|
+
|
1472
|
+
:param bool allow_control_chars: (optional)
|
1473
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
1474
|
+
By default, the response will not allow control characters in strings
|
1475
|
+
|
1476
|
+
:return: A :class:`~oci.response.Response` object with data of type list of :class:`~oci.security_attribute.models.SecurityAttributeNamespaceSummary`
|
1477
|
+
:rtype: :class:`~oci.response.Response`
|
1478
|
+
|
1479
|
+
:example:
|
1480
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/list_security_attribute_namespaces.py.html>`__ to see an example of how to use list_security_attribute_namespaces API.
|
1481
|
+
"""
|
1482
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
1483
|
+
required_arguments = []
|
1484
|
+
resource_path = "/securityAttributeNamespaces"
|
1485
|
+
method = "GET"
|
1486
|
+
operation_name = "list_security_attribute_namespaces"
|
1487
|
+
api_reference_link = ""
|
1488
|
+
|
1489
|
+
# Don't accept unknown kwargs
|
1490
|
+
expected_kwargs = [
|
1491
|
+
"allow_control_chars",
|
1492
|
+
"retry_strategy",
|
1493
|
+
"compartment_id",
|
1494
|
+
"page",
|
1495
|
+
"limit",
|
1496
|
+
"sort_order",
|
1497
|
+
"sort_by",
|
1498
|
+
"name",
|
1499
|
+
"opc_request_id",
|
1500
|
+
"compartment_id_in_subtree",
|
1501
|
+
"lifecycle_state"
|
1502
|
+
]
|
1503
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
1504
|
+
if extra_kwargs:
|
1505
|
+
raise ValueError(
|
1506
|
+
f"list_security_attribute_namespaces got unknown kwargs: {extra_kwargs!r}")
|
1507
|
+
|
1508
|
+
if 'sort_order' in kwargs:
|
1509
|
+
sort_order_allowed_values = ["ASC", "DESC"]
|
1510
|
+
if kwargs['sort_order'] not in sort_order_allowed_values:
|
1511
|
+
raise ValueError(
|
1512
|
+
f"Invalid value for `sort_order`, must be one of { sort_order_allowed_values }"
|
1513
|
+
)
|
1514
|
+
|
1515
|
+
if 'sort_by' in kwargs:
|
1516
|
+
sort_by_allowed_values = ["TIMECREATED", "NAME"]
|
1517
|
+
if kwargs['sort_by'] not in sort_by_allowed_values:
|
1518
|
+
raise ValueError(
|
1519
|
+
f"Invalid value for `sort_by`, must be one of { sort_by_allowed_values }"
|
1520
|
+
)
|
1521
|
+
|
1522
|
+
if 'lifecycle_state' in kwargs:
|
1523
|
+
lifecycle_state_allowed_values = ["ACTIVE", "INACTIVE", "DELETING", "DELETED"]
|
1524
|
+
if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values:
|
1525
|
+
raise ValueError(
|
1526
|
+
f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }"
|
1527
|
+
)
|
1528
|
+
|
1529
|
+
query_params = {
|
1530
|
+
"compartmentId": kwargs.get("compartment_id", missing),
|
1531
|
+
"page": kwargs.get("page", missing),
|
1532
|
+
"limit": kwargs.get("limit", missing),
|
1533
|
+
"sortOrder": kwargs.get("sort_order", missing),
|
1534
|
+
"sortBy": kwargs.get("sort_by", missing),
|
1535
|
+
"name": kwargs.get("name", missing),
|
1536
|
+
"compartmentIdInSubtree": kwargs.get("compartment_id_in_subtree", missing),
|
1537
|
+
"lifecycleState": kwargs.get("lifecycle_state", missing)
|
1538
|
+
}
|
1539
|
+
query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
|
1540
|
+
|
1541
|
+
header_params = {
|
1542
|
+
"accept": "application/json",
|
1543
|
+
"content-type": "application/json",
|
1544
|
+
"opc-request-id": kwargs.get("opc_request_id", missing)
|
1545
|
+
}
|
1546
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
1547
|
+
|
1548
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
1549
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
1550
|
+
client_retry_strategy=self.retry_strategy
|
1551
|
+
)
|
1552
|
+
if retry_strategy is None:
|
1553
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
1554
|
+
|
1555
|
+
if retry_strategy:
|
1556
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
1557
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
1558
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
1559
|
+
return retry_strategy.make_retrying_call(
|
1560
|
+
self.base_client.call_api,
|
1561
|
+
resource_path=resource_path,
|
1562
|
+
method=method,
|
1563
|
+
query_params=query_params,
|
1564
|
+
header_params=header_params,
|
1565
|
+
response_type="list[SecurityAttributeNamespaceSummary]",
|
1566
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1567
|
+
operation_name=operation_name,
|
1568
|
+
api_reference_link=api_reference_link,
|
1569
|
+
required_arguments=required_arguments)
|
1570
|
+
else:
|
1571
|
+
return self.base_client.call_api(
|
1572
|
+
resource_path=resource_path,
|
1573
|
+
method=method,
|
1574
|
+
query_params=query_params,
|
1575
|
+
header_params=header_params,
|
1576
|
+
response_type="list[SecurityAttributeNamespaceSummary]",
|
1577
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1578
|
+
operation_name=operation_name,
|
1579
|
+
api_reference_link=api_reference_link,
|
1580
|
+
required_arguments=required_arguments)
|
1581
|
+
|
1582
|
+
def list_security_attribute_work_request_errors(self, work_request_id, **kwargs):
|
1583
|
+
"""
|
1584
|
+
Gets the errors for a work request.
|
1585
|
+
|
1586
|
+
|
1587
|
+
:param str work_request_id: (required)
|
1588
|
+
The OCID of the work request.
|
1589
|
+
|
1590
|
+
:param str page: (optional)
|
1591
|
+
The value of the `opc-next-page` response header from the previous \"List\" call.
|
1592
|
+
|
1593
|
+
:param int limit: (optional)
|
1594
|
+
The maximum number of items to return in a paginated \"List\" call.
|
1595
|
+
|
1596
|
+
:param str opc_request_id: (optional)
|
1597
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
1598
|
+
Oracle about a particular request, please provide the request ID.
|
1599
|
+
The only valid characters for request IDs are letters, numbers,
|
1600
|
+
underscore, and dash.
|
1601
|
+
|
1602
|
+
:param obj retry_strategy: (optional)
|
1603
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
1604
|
+
|
1605
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
1606
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
1607
|
+
|
1608
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
1609
|
+
|
1610
|
+
:param bool allow_control_chars: (optional)
|
1611
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
1612
|
+
By default, the response will not allow control characters in strings
|
1613
|
+
|
1614
|
+
:return: A :class:`~oci.response.Response` object with data of type list of :class:`~oci.security_attribute.models.SecurityAttributeWorkRequestErrorSummary`
|
1615
|
+
:rtype: :class:`~oci.response.Response`
|
1616
|
+
|
1617
|
+
:example:
|
1618
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/list_security_attribute_work_request_errors.py.html>`__ to see an example of how to use list_security_attribute_work_request_errors API.
|
1619
|
+
"""
|
1620
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
1621
|
+
required_arguments = ['workRequestId']
|
1622
|
+
resource_path = "/securityAttributeWorkRequests/{workRequestId}/errors"
|
1623
|
+
method = "GET"
|
1624
|
+
operation_name = "list_security_attribute_work_request_errors"
|
1625
|
+
api_reference_link = ""
|
1626
|
+
|
1627
|
+
# Don't accept unknown kwargs
|
1628
|
+
expected_kwargs = [
|
1629
|
+
"allow_control_chars",
|
1630
|
+
"retry_strategy",
|
1631
|
+
"page",
|
1632
|
+
"limit",
|
1633
|
+
"opc_request_id"
|
1634
|
+
]
|
1635
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
1636
|
+
if extra_kwargs:
|
1637
|
+
raise ValueError(
|
1638
|
+
f"list_security_attribute_work_request_errors got unknown kwargs: {extra_kwargs!r}")
|
1639
|
+
|
1640
|
+
path_params = {
|
1641
|
+
"workRequestId": work_request_id
|
1642
|
+
}
|
1643
|
+
|
1644
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
1645
|
+
|
1646
|
+
for (k, v) in six.iteritems(path_params):
|
1647
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
1648
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
1649
|
+
|
1650
|
+
query_params = {
|
1651
|
+
"page": kwargs.get("page", missing),
|
1652
|
+
"limit": kwargs.get("limit", missing)
|
1653
|
+
}
|
1654
|
+
query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
|
1655
|
+
|
1656
|
+
header_params = {
|
1657
|
+
"accept": "application/json",
|
1658
|
+
"content-type": "application/json",
|
1659
|
+
"opc-request-id": kwargs.get("opc_request_id", missing)
|
1660
|
+
}
|
1661
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
1662
|
+
|
1663
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
1664
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
1665
|
+
client_retry_strategy=self.retry_strategy
|
1666
|
+
)
|
1667
|
+
if retry_strategy is None:
|
1668
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
1669
|
+
|
1670
|
+
if retry_strategy:
|
1671
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
1672
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
1673
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
1674
|
+
return retry_strategy.make_retrying_call(
|
1675
|
+
self.base_client.call_api,
|
1676
|
+
resource_path=resource_path,
|
1677
|
+
method=method,
|
1678
|
+
path_params=path_params,
|
1679
|
+
query_params=query_params,
|
1680
|
+
header_params=header_params,
|
1681
|
+
response_type="list[SecurityAttributeWorkRequestErrorSummary]",
|
1682
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1683
|
+
operation_name=operation_name,
|
1684
|
+
api_reference_link=api_reference_link,
|
1685
|
+
required_arguments=required_arguments)
|
1686
|
+
else:
|
1687
|
+
return self.base_client.call_api(
|
1688
|
+
resource_path=resource_path,
|
1689
|
+
method=method,
|
1690
|
+
path_params=path_params,
|
1691
|
+
query_params=query_params,
|
1692
|
+
header_params=header_params,
|
1693
|
+
response_type="list[SecurityAttributeWorkRequestErrorSummary]",
|
1694
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1695
|
+
operation_name=operation_name,
|
1696
|
+
api_reference_link=api_reference_link,
|
1697
|
+
required_arguments=required_arguments)
|
1698
|
+
|
1699
|
+
def list_security_attribute_work_request_logs(self, work_request_id, **kwargs):
|
1700
|
+
"""
|
1701
|
+
Gets the logs for a work request.
|
1702
|
+
|
1703
|
+
|
1704
|
+
:param str work_request_id: (required)
|
1705
|
+
The OCID of the work request.
|
1706
|
+
|
1707
|
+
:param str page: (optional)
|
1708
|
+
The value of the `opc-next-page` response header from the previous \"List\" call.
|
1709
|
+
|
1710
|
+
:param int limit: (optional)
|
1711
|
+
The maximum number of items to return in a paginated \"List\" call.
|
1712
|
+
|
1713
|
+
:param str opc_request_id: (optional)
|
1714
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
1715
|
+
Oracle about a particular request, please provide the request ID.
|
1716
|
+
The only valid characters for request IDs are letters, numbers,
|
1717
|
+
underscore, and dash.
|
1718
|
+
|
1719
|
+
:param obj retry_strategy: (optional)
|
1720
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
1721
|
+
|
1722
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
1723
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
1724
|
+
|
1725
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
1726
|
+
|
1727
|
+
:param bool allow_control_chars: (optional)
|
1728
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
1729
|
+
By default, the response will not allow control characters in strings
|
1730
|
+
|
1731
|
+
:return: A :class:`~oci.response.Response` object with data of type list of :class:`~oci.security_attribute.models.SecurityAttributeWorkRequestLogSummary`
|
1732
|
+
:rtype: :class:`~oci.response.Response`
|
1733
|
+
|
1734
|
+
:example:
|
1735
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/list_security_attribute_work_request_logs.py.html>`__ to see an example of how to use list_security_attribute_work_request_logs API.
|
1736
|
+
"""
|
1737
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
1738
|
+
required_arguments = ['workRequestId']
|
1739
|
+
resource_path = "/securityAttributeWorkRequests/{workRequestId}/logs"
|
1740
|
+
method = "GET"
|
1741
|
+
operation_name = "list_security_attribute_work_request_logs"
|
1742
|
+
api_reference_link = ""
|
1743
|
+
|
1744
|
+
# Don't accept unknown kwargs
|
1745
|
+
expected_kwargs = [
|
1746
|
+
"allow_control_chars",
|
1747
|
+
"retry_strategy",
|
1748
|
+
"page",
|
1749
|
+
"limit",
|
1750
|
+
"opc_request_id"
|
1751
|
+
]
|
1752
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
1753
|
+
if extra_kwargs:
|
1754
|
+
raise ValueError(
|
1755
|
+
f"list_security_attribute_work_request_logs got unknown kwargs: {extra_kwargs!r}")
|
1756
|
+
|
1757
|
+
path_params = {
|
1758
|
+
"workRequestId": work_request_id
|
1759
|
+
}
|
1760
|
+
|
1761
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
1762
|
+
|
1763
|
+
for (k, v) in six.iteritems(path_params):
|
1764
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
1765
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
1766
|
+
|
1767
|
+
query_params = {
|
1768
|
+
"page": kwargs.get("page", missing),
|
1769
|
+
"limit": kwargs.get("limit", missing)
|
1770
|
+
}
|
1771
|
+
query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
|
1772
|
+
|
1773
|
+
header_params = {
|
1774
|
+
"accept": "application/json",
|
1775
|
+
"content-type": "application/json",
|
1776
|
+
"opc-request-id": kwargs.get("opc_request_id", missing)
|
1777
|
+
}
|
1778
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
1779
|
+
|
1780
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
1781
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
1782
|
+
client_retry_strategy=self.retry_strategy
|
1783
|
+
)
|
1784
|
+
if retry_strategy is None:
|
1785
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
1786
|
+
|
1787
|
+
if retry_strategy:
|
1788
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
1789
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
1790
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
1791
|
+
return retry_strategy.make_retrying_call(
|
1792
|
+
self.base_client.call_api,
|
1793
|
+
resource_path=resource_path,
|
1794
|
+
method=method,
|
1795
|
+
path_params=path_params,
|
1796
|
+
query_params=query_params,
|
1797
|
+
header_params=header_params,
|
1798
|
+
response_type="list[SecurityAttributeWorkRequestLogSummary]",
|
1799
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1800
|
+
operation_name=operation_name,
|
1801
|
+
api_reference_link=api_reference_link,
|
1802
|
+
required_arguments=required_arguments)
|
1803
|
+
else:
|
1804
|
+
return self.base_client.call_api(
|
1805
|
+
resource_path=resource_path,
|
1806
|
+
method=method,
|
1807
|
+
path_params=path_params,
|
1808
|
+
query_params=query_params,
|
1809
|
+
header_params=header_params,
|
1810
|
+
response_type="list[SecurityAttributeWorkRequestLogSummary]",
|
1811
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1812
|
+
operation_name=operation_name,
|
1813
|
+
api_reference_link=api_reference_link,
|
1814
|
+
required_arguments=required_arguments)
|
1815
|
+
|
1816
|
+
def list_security_attribute_work_requests(self, **kwargs):
|
1817
|
+
"""
|
1818
|
+
Lists the security attribute work requests in compartment.
|
1819
|
+
|
1820
|
+
|
1821
|
+
:param str compartment_id: (optional)
|
1822
|
+
The `OCID`__ of the compartment in which to list resources.
|
1823
|
+
|
1824
|
+
__ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm
|
1825
|
+
|
1826
|
+
:param str page: (optional)
|
1827
|
+
The value of the `opc-next-page` response header from the previous \"List\" call.
|
1828
|
+
|
1829
|
+
:param int limit: (optional)
|
1830
|
+
The maximum number of items to return in a paginated \"List\" call.
|
1831
|
+
|
1832
|
+
:param str resource_identifier: (optional)
|
1833
|
+
The identifier of the resource the work request affects.
|
1834
|
+
|
1835
|
+
:param str opc_request_id: (optional)
|
1836
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
1837
|
+
Oracle about a particular request, please provide the request ID.
|
1838
|
+
The only valid characters for request IDs are letters, numbers,
|
1839
|
+
underscore, and dash.
|
1840
|
+
|
1841
|
+
:param obj retry_strategy: (optional)
|
1842
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
1843
|
+
|
1844
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
1845
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
1846
|
+
|
1847
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
1848
|
+
|
1849
|
+
:param bool allow_control_chars: (optional)
|
1850
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
1851
|
+
By default, the response will not allow control characters in strings
|
1852
|
+
|
1853
|
+
:return: A :class:`~oci.response.Response` object with data of type list of :class:`~oci.security_attribute.models.SecurityAttributeWorkRequestSummary`
|
1854
|
+
:rtype: :class:`~oci.response.Response`
|
1855
|
+
|
1856
|
+
:example:
|
1857
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/list_security_attribute_work_requests.py.html>`__ to see an example of how to use list_security_attribute_work_requests API.
|
1858
|
+
"""
|
1859
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
1860
|
+
required_arguments = []
|
1861
|
+
resource_path = "/securityAttributeWorkRequests"
|
1862
|
+
method = "GET"
|
1863
|
+
operation_name = "list_security_attribute_work_requests"
|
1864
|
+
api_reference_link = ""
|
1865
|
+
|
1866
|
+
# Don't accept unknown kwargs
|
1867
|
+
expected_kwargs = [
|
1868
|
+
"allow_control_chars",
|
1869
|
+
"retry_strategy",
|
1870
|
+
"compartment_id",
|
1871
|
+
"page",
|
1872
|
+
"limit",
|
1873
|
+
"resource_identifier",
|
1874
|
+
"opc_request_id"
|
1875
|
+
]
|
1876
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
1877
|
+
if extra_kwargs:
|
1878
|
+
raise ValueError(
|
1879
|
+
f"list_security_attribute_work_requests got unknown kwargs: {extra_kwargs!r}")
|
1880
|
+
|
1881
|
+
query_params = {
|
1882
|
+
"compartmentId": kwargs.get("compartment_id", missing),
|
1883
|
+
"page": kwargs.get("page", missing),
|
1884
|
+
"limit": kwargs.get("limit", missing),
|
1885
|
+
"resourceIdentifier": kwargs.get("resource_identifier", missing)
|
1886
|
+
}
|
1887
|
+
query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
|
1888
|
+
|
1889
|
+
header_params = {
|
1890
|
+
"accept": "application/json",
|
1891
|
+
"content-type": "application/json",
|
1892
|
+
"opc-request-id": kwargs.get("opc_request_id", missing)
|
1893
|
+
}
|
1894
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
1895
|
+
|
1896
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
1897
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
1898
|
+
client_retry_strategy=self.retry_strategy
|
1899
|
+
)
|
1900
|
+
if retry_strategy is None:
|
1901
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
1902
|
+
|
1903
|
+
if retry_strategy:
|
1904
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
1905
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
1906
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
1907
|
+
return retry_strategy.make_retrying_call(
|
1908
|
+
self.base_client.call_api,
|
1909
|
+
resource_path=resource_path,
|
1910
|
+
method=method,
|
1911
|
+
query_params=query_params,
|
1912
|
+
header_params=header_params,
|
1913
|
+
response_type="list[SecurityAttributeWorkRequestSummary]",
|
1914
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1915
|
+
operation_name=operation_name,
|
1916
|
+
api_reference_link=api_reference_link,
|
1917
|
+
required_arguments=required_arguments)
|
1918
|
+
else:
|
1919
|
+
return self.base_client.call_api(
|
1920
|
+
resource_path=resource_path,
|
1921
|
+
method=method,
|
1922
|
+
query_params=query_params,
|
1923
|
+
header_params=header_params,
|
1924
|
+
response_type="list[SecurityAttributeWorkRequestSummary]",
|
1925
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
1926
|
+
operation_name=operation_name,
|
1927
|
+
api_reference_link=api_reference_link,
|
1928
|
+
required_arguments=required_arguments)
|
1929
|
+
|
1930
|
+
def list_security_attributes(self, security_attribute_namespace_id, **kwargs):
|
1931
|
+
"""
|
1932
|
+
Lists the security attributes in the specified namespace.
|
1933
|
+
|
1934
|
+
|
1935
|
+
:param str security_attribute_namespace_id: (required)
|
1936
|
+
The OCID of the security attribute namespace.
|
1937
|
+
|
1938
|
+
:param str page: (optional)
|
1939
|
+
The value of the `opc-next-page` response header from the previous \"List\" call.
|
1940
|
+
|
1941
|
+
:param int limit: (optional)
|
1942
|
+
The maximum number of items to return in a paginated \"List\" call.
|
1943
|
+
|
1944
|
+
:param str opc_request_id: (optional)
|
1945
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
1946
|
+
Oracle about a particular request, please provide the request ID.
|
1947
|
+
The only valid characters for request IDs are letters, numbers,
|
1948
|
+
underscore, and dash.
|
1949
|
+
|
1950
|
+
:param str lifecycle_state: (optional)
|
1951
|
+
A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
|
1952
|
+
|
1953
|
+
Allowed values are: "ACTIVE", "INACTIVE", "DELETING", "DELETED"
|
1954
|
+
|
1955
|
+
:param obj retry_strategy: (optional)
|
1956
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
1957
|
+
|
1958
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
1959
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
1960
|
+
|
1961
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
1962
|
+
|
1963
|
+
:param bool allow_control_chars: (optional)
|
1964
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
1965
|
+
By default, the response will not allow control characters in strings
|
1966
|
+
|
1967
|
+
:return: A :class:`~oci.response.Response` object with data of type list of :class:`~oci.security_attribute.models.SecurityAttributeSummary`
|
1968
|
+
:rtype: :class:`~oci.response.Response`
|
1969
|
+
|
1970
|
+
:example:
|
1971
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/list_security_attributes.py.html>`__ to see an example of how to use list_security_attributes API.
|
1972
|
+
"""
|
1973
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
1974
|
+
required_arguments = ['securityAttributeNamespaceId']
|
1975
|
+
resource_path = "/securityAttributeNamespaces/{securityAttributeNamespaceId}/securityAttributes"
|
1976
|
+
method = "GET"
|
1977
|
+
operation_name = "list_security_attributes"
|
1978
|
+
api_reference_link = ""
|
1979
|
+
|
1980
|
+
# Don't accept unknown kwargs
|
1981
|
+
expected_kwargs = [
|
1982
|
+
"allow_control_chars",
|
1983
|
+
"retry_strategy",
|
1984
|
+
"page",
|
1985
|
+
"limit",
|
1986
|
+
"opc_request_id",
|
1987
|
+
"lifecycle_state"
|
1988
|
+
]
|
1989
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
1990
|
+
if extra_kwargs:
|
1991
|
+
raise ValueError(
|
1992
|
+
f"list_security_attributes got unknown kwargs: {extra_kwargs!r}")
|
1993
|
+
|
1994
|
+
path_params = {
|
1995
|
+
"securityAttributeNamespaceId": security_attribute_namespace_id
|
1996
|
+
}
|
1997
|
+
|
1998
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
1999
|
+
|
2000
|
+
for (k, v) in six.iteritems(path_params):
|
2001
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
2002
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
2003
|
+
|
2004
|
+
if 'lifecycle_state' in kwargs:
|
2005
|
+
lifecycle_state_allowed_values = ["ACTIVE", "INACTIVE", "DELETING", "DELETED"]
|
2006
|
+
if kwargs['lifecycle_state'] not in lifecycle_state_allowed_values:
|
2007
|
+
raise ValueError(
|
2008
|
+
f"Invalid value for `lifecycle_state`, must be one of { lifecycle_state_allowed_values }"
|
2009
|
+
)
|
2010
|
+
|
2011
|
+
query_params = {
|
2012
|
+
"page": kwargs.get("page", missing),
|
2013
|
+
"limit": kwargs.get("limit", missing),
|
2014
|
+
"lifecycleState": kwargs.get("lifecycle_state", missing)
|
2015
|
+
}
|
2016
|
+
query_params = {k: v for (k, v) in six.iteritems(query_params) if v is not missing and v is not None}
|
2017
|
+
|
2018
|
+
header_params = {
|
2019
|
+
"accept": "application/json",
|
2020
|
+
"content-type": "application/json",
|
2021
|
+
"opc-request-id": kwargs.get("opc_request_id", missing)
|
2022
|
+
}
|
2023
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
2024
|
+
|
2025
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
2026
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
2027
|
+
client_retry_strategy=self.retry_strategy
|
2028
|
+
)
|
2029
|
+
if retry_strategy is None:
|
2030
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
2031
|
+
|
2032
|
+
if retry_strategy:
|
2033
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
2034
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
2035
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
2036
|
+
return retry_strategy.make_retrying_call(
|
2037
|
+
self.base_client.call_api,
|
2038
|
+
resource_path=resource_path,
|
2039
|
+
method=method,
|
2040
|
+
path_params=path_params,
|
2041
|
+
query_params=query_params,
|
2042
|
+
header_params=header_params,
|
2043
|
+
response_type="list[SecurityAttributeSummary]",
|
2044
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
2045
|
+
operation_name=operation_name,
|
2046
|
+
api_reference_link=api_reference_link,
|
2047
|
+
required_arguments=required_arguments)
|
2048
|
+
else:
|
2049
|
+
return self.base_client.call_api(
|
2050
|
+
resource_path=resource_path,
|
2051
|
+
method=method,
|
2052
|
+
path_params=path_params,
|
2053
|
+
query_params=query_params,
|
2054
|
+
header_params=header_params,
|
2055
|
+
response_type="list[SecurityAttributeSummary]",
|
2056
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
2057
|
+
operation_name=operation_name,
|
2058
|
+
api_reference_link=api_reference_link,
|
2059
|
+
required_arguments=required_arguments)
|
2060
|
+
|
2061
|
+
def update_security_attribute(self, security_attribute_namespace_id, security_attribute_name, update_security_attribute_details, **kwargs):
|
2062
|
+
"""
|
2063
|
+
Updates the specified security attribute. You can only update `description`, and `isRetired`.
|
2064
|
+
|
2065
|
+
|
2066
|
+
:param str security_attribute_namespace_id: (required)
|
2067
|
+
The OCID of the security attribute namespace.
|
2068
|
+
|
2069
|
+
:param str security_attribute_name: (required)
|
2070
|
+
The name of the security attribute.
|
2071
|
+
|
2072
|
+
:param oci.security_attribute.models.UpdateSecurityAttributeDetails update_security_attribute_details: (required)
|
2073
|
+
Request object for updating a security attribute.
|
2074
|
+
|
2075
|
+
:param str if_match: (optional)
|
2076
|
+
For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
|
2077
|
+
`if-match` parameter to the value of the etag from a previous GET or POST response for
|
2078
|
+
that resource. The resource will be updated or deleted only if the etag you provide
|
2079
|
+
matches the resource's current etag value.
|
2080
|
+
|
2081
|
+
:param str opc_request_id: (optional)
|
2082
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
2083
|
+
Oracle about a particular request, please provide the request ID.
|
2084
|
+
The only valid characters for request IDs are letters, numbers,
|
2085
|
+
underscore, and dash.
|
2086
|
+
|
2087
|
+
:param str opc_retry_token: (optional)
|
2088
|
+
A token that uniquely identifies a request so it can be retried in case of a timeout or
|
2089
|
+
server error without risk of running that same action again. Retry tokens expire after 24
|
2090
|
+
hours, but can be invalidated before then due to conflicting operations. For example, if a resource
|
2091
|
+
has been deleted and removed from the system, then a retry of the original creation request
|
2092
|
+
might be rejected.
|
2093
|
+
|
2094
|
+
:param obj retry_strategy: (optional)
|
2095
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
2096
|
+
|
2097
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
2098
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
2099
|
+
|
2100
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
2101
|
+
|
2102
|
+
:param bool allow_control_chars: (optional)
|
2103
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
2104
|
+
By default, the response will not allow control characters in strings
|
2105
|
+
|
2106
|
+
:return: A :class:`~oci.response.Response` object with data of type :class:`~oci.security_attribute.models.SecurityAttribute`
|
2107
|
+
:rtype: :class:`~oci.response.Response`
|
2108
|
+
|
2109
|
+
:example:
|
2110
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/update_security_attribute.py.html>`__ to see an example of how to use update_security_attribute API.
|
2111
|
+
"""
|
2112
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
2113
|
+
required_arguments = ['securityAttributeNamespaceId', 'securityAttributeName']
|
2114
|
+
resource_path = "/securityAttributeNamespaces/{securityAttributeNamespaceId}/securityAttributes/{securityAttributeName}"
|
2115
|
+
method = "PUT"
|
2116
|
+
operation_name = "update_security_attribute"
|
2117
|
+
api_reference_link = ""
|
2118
|
+
|
2119
|
+
# Don't accept unknown kwargs
|
2120
|
+
expected_kwargs = [
|
2121
|
+
"allow_control_chars",
|
2122
|
+
"retry_strategy",
|
2123
|
+
"if_match",
|
2124
|
+
"opc_request_id",
|
2125
|
+
"opc_retry_token"
|
2126
|
+
]
|
2127
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
2128
|
+
if extra_kwargs:
|
2129
|
+
raise ValueError(
|
2130
|
+
f"update_security_attribute got unknown kwargs: {extra_kwargs!r}")
|
2131
|
+
|
2132
|
+
path_params = {
|
2133
|
+
"securityAttributeNamespaceId": security_attribute_namespace_id,
|
2134
|
+
"securityAttributeName": security_attribute_name
|
2135
|
+
}
|
2136
|
+
|
2137
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
2138
|
+
|
2139
|
+
for (k, v) in six.iteritems(path_params):
|
2140
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
2141
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
2142
|
+
|
2143
|
+
header_params = {
|
2144
|
+
"accept": "application/json",
|
2145
|
+
"content-type": "application/json",
|
2146
|
+
"if-match": kwargs.get("if_match", missing),
|
2147
|
+
"opc-request-id": kwargs.get("opc_request_id", missing),
|
2148
|
+
"opc-retry-token": kwargs.get("opc_retry_token", missing)
|
2149
|
+
}
|
2150
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
2151
|
+
|
2152
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
2153
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
2154
|
+
client_retry_strategy=self.retry_strategy
|
2155
|
+
)
|
2156
|
+
if retry_strategy is None:
|
2157
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
2158
|
+
|
2159
|
+
if retry_strategy:
|
2160
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
2161
|
+
self.base_client.add_opc_retry_token_if_needed(header_params)
|
2162
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
2163
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
2164
|
+
return retry_strategy.make_retrying_call(
|
2165
|
+
self.base_client.call_api,
|
2166
|
+
resource_path=resource_path,
|
2167
|
+
method=method,
|
2168
|
+
path_params=path_params,
|
2169
|
+
header_params=header_params,
|
2170
|
+
body=update_security_attribute_details,
|
2171
|
+
response_type="SecurityAttribute",
|
2172
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
2173
|
+
operation_name=operation_name,
|
2174
|
+
api_reference_link=api_reference_link,
|
2175
|
+
required_arguments=required_arguments)
|
2176
|
+
else:
|
2177
|
+
return self.base_client.call_api(
|
2178
|
+
resource_path=resource_path,
|
2179
|
+
method=method,
|
2180
|
+
path_params=path_params,
|
2181
|
+
header_params=header_params,
|
2182
|
+
body=update_security_attribute_details,
|
2183
|
+
response_type="SecurityAttribute",
|
2184
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
2185
|
+
operation_name=operation_name,
|
2186
|
+
api_reference_link=api_reference_link,
|
2187
|
+
required_arguments=required_arguments)
|
2188
|
+
|
2189
|
+
def update_security_attribute_namespace(self, security_attribute_namespace_id, update_security_attribute_namespace_details, **kwargs):
|
2190
|
+
"""
|
2191
|
+
Updates the specified security attribute namespace. You can't update the namespace name.
|
2192
|
+
|
2193
|
+
Updating `isRetired` to 'true' retires the namespace and all the security attributes in the namespace. Reactivating a
|
2194
|
+
namespace (changing `isRetired` from 'true' to 'false') does not reactivate security attributes.
|
2195
|
+
To reactivate the security attributes, you must reactivate each one individually *after* you reactivate the namespace,
|
2196
|
+
using :func:`update_tag`. For more information about retiring security attribute namespaces, see
|
2197
|
+
`Managing Security Attribute Namespaces`__.
|
2198
|
+
|
2199
|
+
You can't add a namespace with the same name as a retired namespace in the same tenancy.
|
2200
|
+
|
2201
|
+
__ https://docs.cloud.oracle.com/Content/zero-trust-packet-routing/managing-security-attribute-namespaces.htm
|
2202
|
+
|
2203
|
+
|
2204
|
+
:param str security_attribute_namespace_id: (required)
|
2205
|
+
The OCID of the security attribute namespace.
|
2206
|
+
|
2207
|
+
:param oci.security_attribute.models.UpdateSecurityAttributeNamespaceDetails update_security_attribute_namespace_details: (required)
|
2208
|
+
Request object for updating a namespace.
|
2209
|
+
|
2210
|
+
:param str if_match: (optional)
|
2211
|
+
For optimistic concurrency control. In the PUT or DELETE call for a resource, set the
|
2212
|
+
`if-match` parameter to the value of the etag from a previous GET or POST response for
|
2213
|
+
that resource. The resource will be updated or deleted only if the etag you provide
|
2214
|
+
matches the resource's current etag value.
|
2215
|
+
|
2216
|
+
:param str opc_request_id: (optional)
|
2217
|
+
Unique Oracle-assigned identifier for the request. If you need to contact
|
2218
|
+
Oracle about a particular request, please provide the request ID.
|
2219
|
+
The only valid characters for request IDs are letters, numbers,
|
2220
|
+
underscore, and dash.
|
2221
|
+
|
2222
|
+
:param str opc_retry_token: (optional)
|
2223
|
+
A token that uniquely identifies a request so it can be retried in case of a timeout or
|
2224
|
+
server error without risk of running that same action again. Retry tokens expire after 24
|
2225
|
+
hours, but can be invalidated before then due to conflicting operations. For example, if a resource
|
2226
|
+
has been deleted and removed from the system, then a retry of the original creation request
|
2227
|
+
might be rejected.
|
2228
|
+
|
2229
|
+
:param obj retry_strategy: (optional)
|
2230
|
+
A retry strategy to apply to this specific operation/call. This will override any retry strategy set at the client-level.
|
2231
|
+
|
2232
|
+
This should be one of the strategies available in the :py:mod:`~oci.retry` module. This operation uses :py:data:`~oci.retry.DEFAULT_RETRY_STRATEGY` as default if no retry strategy is provided.
|
2233
|
+
The specifics of the default retry strategy are described `here <https://docs.oracle.com/en-us/iaas/tools/python/latest/sdk_behaviors/retries.html>`__.
|
2234
|
+
|
2235
|
+
To have this operation explicitly not perform any retries, pass an instance of :py:class:`~oci.retry.NoneRetryStrategy`.
|
2236
|
+
|
2237
|
+
:param bool allow_control_chars: (optional)
|
2238
|
+
allow_control_chars is a boolean to indicate whether or not this request should allow control characters in the response object.
|
2239
|
+
By default, the response will not allow control characters in strings
|
2240
|
+
|
2241
|
+
:return: A :class:`~oci.response.Response` object with data of type :class:`~oci.security_attribute.models.SecurityAttributeNamespace`
|
2242
|
+
:rtype: :class:`~oci.response.Response`
|
2243
|
+
|
2244
|
+
:example:
|
2245
|
+
Click `here <https://docs.cloud.oracle.com/en-us/iaas/tools/python-sdk-examples/2.135.2/securityattribute/update_security_attribute_namespace.py.html>`__ to see an example of how to use update_security_attribute_namespace API.
|
2246
|
+
"""
|
2247
|
+
# Required path and query arguments. These are in camelCase to replace values in service endpoints.
|
2248
|
+
required_arguments = ['securityAttributeNamespaceId']
|
2249
|
+
resource_path = "/securityAttributeNamespaces/{securityAttributeNamespaceId}"
|
2250
|
+
method = "PUT"
|
2251
|
+
operation_name = "update_security_attribute_namespace"
|
2252
|
+
api_reference_link = ""
|
2253
|
+
|
2254
|
+
# Don't accept unknown kwargs
|
2255
|
+
expected_kwargs = [
|
2256
|
+
"allow_control_chars",
|
2257
|
+
"retry_strategy",
|
2258
|
+
"if_match",
|
2259
|
+
"opc_request_id",
|
2260
|
+
"opc_retry_token"
|
2261
|
+
]
|
2262
|
+
extra_kwargs = [_key for _key in six.iterkeys(kwargs) if _key not in expected_kwargs]
|
2263
|
+
if extra_kwargs:
|
2264
|
+
raise ValueError(
|
2265
|
+
f"update_security_attribute_namespace got unknown kwargs: {extra_kwargs!r}")
|
2266
|
+
|
2267
|
+
path_params = {
|
2268
|
+
"securityAttributeNamespaceId": security_attribute_namespace_id
|
2269
|
+
}
|
2270
|
+
|
2271
|
+
path_params = {k: v for (k, v) in six.iteritems(path_params) if v is not missing}
|
2272
|
+
|
2273
|
+
for (k, v) in six.iteritems(path_params):
|
2274
|
+
if v is None or (isinstance(v, six.string_types) and len(v.strip()) == 0):
|
2275
|
+
raise ValueError(f'Parameter {k} cannot be None, whitespace or empty string')
|
2276
|
+
|
2277
|
+
header_params = {
|
2278
|
+
"accept": "application/json",
|
2279
|
+
"content-type": "application/json",
|
2280
|
+
"if-match": kwargs.get("if_match", missing),
|
2281
|
+
"opc-request-id": kwargs.get("opc_request_id", missing),
|
2282
|
+
"opc-retry-token": kwargs.get("opc_retry_token", missing)
|
2283
|
+
}
|
2284
|
+
header_params = {k: v for (k, v) in six.iteritems(header_params) if v is not missing and v is not None}
|
2285
|
+
|
2286
|
+
retry_strategy = self.base_client.get_preferred_retry_strategy(
|
2287
|
+
operation_retry_strategy=kwargs.get('retry_strategy'),
|
2288
|
+
client_retry_strategy=self.retry_strategy
|
2289
|
+
)
|
2290
|
+
if retry_strategy is None:
|
2291
|
+
retry_strategy = retry.DEFAULT_RETRY_STRATEGY
|
2292
|
+
|
2293
|
+
if retry_strategy:
|
2294
|
+
if not isinstance(retry_strategy, retry.NoneRetryStrategy):
|
2295
|
+
self.base_client.add_opc_retry_token_if_needed(header_params)
|
2296
|
+
self.base_client.add_opc_client_retries_header(header_params)
|
2297
|
+
retry_strategy.add_circuit_breaker_callback(self.circuit_breaker_callback)
|
2298
|
+
return retry_strategy.make_retrying_call(
|
2299
|
+
self.base_client.call_api,
|
2300
|
+
resource_path=resource_path,
|
2301
|
+
method=method,
|
2302
|
+
path_params=path_params,
|
2303
|
+
header_params=header_params,
|
2304
|
+
body=update_security_attribute_namespace_details,
|
2305
|
+
response_type="SecurityAttributeNamespace",
|
2306
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
2307
|
+
operation_name=operation_name,
|
2308
|
+
api_reference_link=api_reference_link,
|
2309
|
+
required_arguments=required_arguments)
|
2310
|
+
else:
|
2311
|
+
return self.base_client.call_api(
|
2312
|
+
resource_path=resource_path,
|
2313
|
+
method=method,
|
2314
|
+
path_params=path_params,
|
2315
|
+
header_params=header_params,
|
2316
|
+
body=update_security_attribute_namespace_details,
|
2317
|
+
response_type="SecurityAttributeNamespace",
|
2318
|
+
allow_control_chars=kwargs.get('allow_control_chars'),
|
2319
|
+
operation_name=operation_name,
|
2320
|
+
api_reference_link=api_reference_link,
|
2321
|
+
required_arguments=required_arguments)
|