Oracle Cloud Infrastructure v2.29.0 published on Wednesday, Apr 9, 2025 by Pulumi
oci.SecurityAttribute.getSecurityAttributes
Explore with Pulumi AI
This data source provides the list of Security Attributes in Oracle Cloud Infrastructure Security Attribute service.
Lists the security attributes in the specified namespace.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testSecurityAttributes = oci.SecurityAttribute.getSecurityAttributes({
securityAttributeNamespaceId: testSecurityAttributeNamespace.id,
state: securityAttributeState,
});
import pulumi
import pulumi_oci as oci
test_security_attributes = oci.SecurityAttribute.get_security_attributes(security_attribute_namespace_id=test_security_attribute_namespace["id"],
state=security_attribute_state)
package main
import (
"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/securityattribute"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := securityattribute.GetSecurityAttributes(ctx, &securityattribute.GetSecurityAttributesArgs{
SecurityAttributeNamespaceId: testSecurityAttributeNamespace.Id,
State: pulumi.StringRef(securityAttributeState),
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;
return await Deployment.RunAsync(() =>
{
var testSecurityAttributes = Oci.SecurityAttribute.GetSecurityAttributes.Invoke(new()
{
SecurityAttributeNamespaceId = testSecurityAttributeNamespace.Id,
State = securityAttributeState,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.SecurityAttribute.SecurityAttributeFunctions;
import com.pulumi.oci.SecurityAttribute.inputs.GetSecurityAttributesArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var testSecurityAttributes = SecurityAttributeFunctions.getSecurityAttributes(GetSecurityAttributesArgs.builder()
.securityAttributeNamespaceId(testSecurityAttributeNamespace.id())
.state(securityAttributeState)
.build());
}
}
variables:
testSecurityAttributes:
fn::invoke:
function: oci:SecurityAttribute:getSecurityAttributes
arguments:
securityAttributeNamespaceId: ${testSecurityAttributeNamespace.id}
state: ${securityAttributeState}
Using getSecurityAttributes
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getSecurityAttributes(args: GetSecurityAttributesArgs, opts?: InvokeOptions): Promise<GetSecurityAttributesResult>
function getSecurityAttributesOutput(args: GetSecurityAttributesOutputArgs, opts?: InvokeOptions): Output<GetSecurityAttributesResult>
def get_security_attributes(filters: Optional[Sequence[_securityattribute.GetSecurityAttributesFilter]] = None,
security_attribute_namespace_id: Optional[str] = None,
state: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetSecurityAttributesResult
def get_security_attributes_output(filters: Optional[pulumi.Input[Sequence[pulumi.Input[_securityattribute.GetSecurityAttributesFilterArgs]]]] = None,
security_attribute_namespace_id: Optional[pulumi.Input[str]] = None,
state: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetSecurityAttributesResult]
func GetSecurityAttributes(ctx *Context, args *GetSecurityAttributesArgs, opts ...InvokeOption) (*GetSecurityAttributesResult, error)
func GetSecurityAttributesOutput(ctx *Context, args *GetSecurityAttributesOutputArgs, opts ...InvokeOption) GetSecurityAttributesResultOutput
> Note: This function is named GetSecurityAttributes
in the Go SDK.
public static class GetSecurityAttributes
{
public static Task<GetSecurityAttributesResult> InvokeAsync(GetSecurityAttributesArgs args, InvokeOptions? opts = null)
public static Output<GetSecurityAttributesResult> Invoke(GetSecurityAttributesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetSecurityAttributesResult> getSecurityAttributes(GetSecurityAttributesArgs args, InvokeOptions options)
public static Output<GetSecurityAttributesResult> getSecurityAttributes(GetSecurityAttributesArgs args, InvokeOptions options)
fn::invoke:
function: oci:SecurityAttribute/getSecurityAttributes:getSecurityAttributes
arguments:
# arguments dictionary
The following arguments are supported:
- Security
Attribute Namespace Id This property is required. string - The OCID of the security attribute namespace.
- Filters
Changes to this property will trigger replacement.
Security Attributes Filter> - State string
- A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
- Security
Attribute Namespace Id This property is required. string - The OCID of the security attribute namespace.
- Filters
Changes to this property will trigger replacement.
Security Attributes Filter - State string
- A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
- security
Attribute Namespace Id This property is required. String - The OCID of the security attribute namespace.
- filters
Changes to this property will trigger replacement.
Filter> - state String
- A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
- security
Attribute Namespace Id This property is required. string - The OCID of the security attribute namespace.
- filters
Changes to this property will trigger replacement.
Security Attributes Filter[] - state string
- A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
- security_
attribute_ namespace_ id This property is required. str - The OCID of the security attribute namespace.
- filters
Changes to this property will trigger replacement.
Get Security Attributes Filter] - state str
- A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
- security
Attribute Namespace Id This property is required. String - The OCID of the security attribute namespace.
- filters
Changes to this property will trigger replacement.
- state String
- A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
getSecurityAttributes Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Security
Attribute stringNamespace Id - The OCID of the security attribute namespace that contains the security attribute definition.
- Security
Attributes List<GetSecurity Attributes Security Attribute> - The list of security_attributes.
- Filters
List<Get
Security Attributes Filter> - State string
- The security attribute's current state. After creating a security attribute, make sure its
lifecycleState
is ACTIVE before using it. After retiring a security attribute, make sure itslifecycleState
is INACTIVE before using it. If you delete a security attribute, you cannot delete another security attribute until the deleted security attribute'slifecycleState
changes from DELETING to DELETED.
- Id string
- The provider-assigned unique ID for this managed resource.
- Security
Attribute stringNamespace Id - The OCID of the security attribute namespace that contains the security attribute definition.
- Security
Attributes []GetSecurity Attributes Security Attribute - The list of security_attributes.
- Filters
[]Get
Security Attributes Filter - State string
- The security attribute's current state. After creating a security attribute, make sure its
lifecycleState
is ACTIVE before using it. After retiring a security attribute, make sure itslifecycleState
is INACTIVE before using it. If you delete a security attribute, you cannot delete another security attribute until the deleted security attribute'slifecycleState
changes from DELETING to DELETED.
- id String
- The provider-assigned unique ID for this managed resource.
- security
Attribute StringNamespace Id - The OCID of the security attribute namespace that contains the security attribute definition.
- security
Attributes List<Gets> - The list of security_attributes.
- filters
List<Gets
Filter> - state String
- The security attribute's current state. After creating a security attribute, make sure its
lifecycleState
is ACTIVE before using it. After retiring a security attribute, make sure itslifecycleState
is INACTIVE before using it. If you delete a security attribute, you cannot delete another security attribute until the deleted security attribute'slifecycleState
changes from DELETING to DELETED.
- id string
- The provider-assigned unique ID for this managed resource.
- security
Attribute stringNamespace Id - The OCID of the security attribute namespace that contains the security attribute definition.
- security
Attributes GetSecurity Attributes Security Attribute[] - The list of security_attributes.
- filters
Get
Security Attributes Filter[] - state string
- The security attribute's current state. After creating a security attribute, make sure its
lifecycleState
is ACTIVE before using it. After retiring a security attribute, make sure itslifecycleState
is INACTIVE before using it. If you delete a security attribute, you cannot delete another security attribute until the deleted security attribute'slifecycleState
changes from DELETING to DELETED.
- id str
- The provider-assigned unique ID for this managed resource.
- security_
attribute_ strnamespace_ id - The OCID of the security attribute namespace that contains the security attribute definition.
- security_
attributes Sequence[securityattribute.Get Security Attributes Security Attribute] - The list of security_attributes.
- filters
Sequence[securityattribute.
Get Security Attributes Filter] - state str
- The security attribute's current state. After creating a security attribute, make sure its
lifecycleState
is ACTIVE before using it. After retiring a security attribute, make sure itslifecycleState
is INACTIVE before using it. If you delete a security attribute, you cannot delete another security attribute until the deleted security attribute'slifecycleState
changes from DELETING to DELETED.
- id String
- The provider-assigned unique ID for this managed resource.
- security
Attribute StringNamespace Id - The OCID of the security attribute namespace that contains the security attribute definition.
- security
Attributes List<Property Map> - The list of security_attributes.
- filters List<Property Map>
- state String
- The security attribute's current state. After creating a security attribute, make sure its
lifecycleState
is ACTIVE before using it. After retiring a security attribute, make sure itslifecycleState
is INACTIVE before using it. If you delete a security attribute, you cannot delete another security attribute until the deleted security attribute'slifecycleState
changes from DELETING to DELETED.
Supporting Types
GetSecurityAttributesFilter
- Name
This property is required. string - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- Values
This property is required. List<string> - The list of allowed values for a security attribute value.
- Regex bool
- Name
This property is required. string - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- Values
This property is required. []string - The list of allowed values for a security attribute value.
- Regex bool
- name
This property is required. String - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- values
This property is required. List<String> - The list of allowed values for a security attribute value.
- regex Boolean
- name
This property is required. string - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- values
This property is required. string[] - The list of allowed values for a security attribute value.
- regex boolean
- name
This property is required. str - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- values
This property is required. Sequence[str] - The list of allowed values for a security attribute value.
- regex bool
- name
This property is required. String - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- values
This property is required. List<String> - The list of allowed values for a security attribute value.
- regex Boolean
GetSecurityAttributesSecurityAttribute
- Compartment
Id This property is required. string - The OCID of the compartment that contains the security attribute definition.
- Description
This property is required. string - The description you assign to the security attribute.
- Id
This property is required. string - The OCID of the security attribute definition.
- Is
Retired This property is required. bool - Indicates whether the security attribute is retired. See Managing Security Attribute Namespaces.
- Name
This property is required. string - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- Security
Attribute Namespace Id This property is required. string - The OCID of the security attribute namespace.
- Security
Attribute Namespace Name This property is required. string - The name of the security attribute namespace that contains the security attribute.
- State
This property is required. string - A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
- Time
Created This property is required. string - Date and time the security attribute was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- Type
This property is required. string - The data type of the security attribute.
- Validators
This property is required. List<GetSecurity Attributes Security Attribute Validator> - Validates a security attribute value. Each validator performs validation steps in addition to the standard validation for security attribute values. For more information, see Limits on Security Attributes.
- Compartment
Id This property is required. string - The OCID of the compartment that contains the security attribute definition.
- Description
This property is required. string - The description you assign to the security attribute.
- Id
This property is required. string - The OCID of the security attribute definition.
- Is
Retired This property is required. bool - Indicates whether the security attribute is retired. See Managing Security Attribute Namespaces.
- Name
This property is required. string - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- Security
Attribute Namespace Id This property is required. string - The OCID of the security attribute namespace.
- Security
Attribute Namespace Name This property is required. string - The name of the security attribute namespace that contains the security attribute.
- State
This property is required. string - A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
- Time
Created This property is required. string - Date and time the security attribute was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- Type
This property is required. string - The data type of the security attribute.
- Validators
This property is required. []GetSecurity Attributes Security Attribute Validator - Validates a security attribute value. Each validator performs validation steps in addition to the standard validation for security attribute values. For more information, see Limits on Security Attributes.
- compartment
Id This property is required. String - The OCID of the compartment that contains the security attribute definition.
- description
This property is required. String - The description you assign to the security attribute.
- id
This property is required. String - The OCID of the security attribute definition.
- is
Retired This property is required. Boolean - Indicates whether the security attribute is retired. See Managing Security Attribute Namespaces.
- name
This property is required. String - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- security
Attribute Namespace Id This property is required. String - The OCID of the security attribute namespace.
- security
Attribute Namespace Name This property is required. String - The name of the security attribute namespace that contains the security attribute.
- state
This property is required. String - A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
- time
Created This property is required. String - Date and time the security attribute was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- type
This property is required. String - The data type of the security attribute.
- validators
This property is required. List<GetsValidator> - Validates a security attribute value. Each validator performs validation steps in addition to the standard validation for security attribute values. For more information, see Limits on Security Attributes.
- compartment
Id This property is required. string - The OCID of the compartment that contains the security attribute definition.
- description
This property is required. string - The description you assign to the security attribute.
- id
This property is required. string - The OCID of the security attribute definition.
- is
Retired This property is required. boolean - Indicates whether the security attribute is retired. See Managing Security Attribute Namespaces.
- name
This property is required. string - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- security
Attribute Namespace Id This property is required. string - The OCID of the security attribute namespace.
- security
Attribute Namespace Name This property is required. string - The name of the security attribute namespace that contains the security attribute.
- state
This property is required. string - A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
- time
Created This property is required. string - Date and time the security attribute was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- type
This property is required. string - The data type of the security attribute.
- validators
This property is required. GetSecurity Attributes Security Attribute Validator[] - Validates a security attribute value. Each validator performs validation steps in addition to the standard validation for security attribute values. For more information, see Limits on Security Attributes.
- compartment_
id This property is required. str - The OCID of the compartment that contains the security attribute definition.
- description
This property is required. str - The description you assign to the security attribute.
- id
This property is required. str - The OCID of the security attribute definition.
- is_
retired This property is required. bool - Indicates whether the security attribute is retired. See Managing Security Attribute Namespaces.
- name
This property is required. str - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- security_
attribute_ namespace_ id This property is required. str - The OCID of the security attribute namespace.
- security_
attribute_ namespace_ name This property is required. str - The name of the security attribute namespace that contains the security attribute.
- state
This property is required. str - A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
- time_
created This property is required. str - Date and time the security attribute was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- type
This property is required. str - The data type of the security attribute.
- validators
This property is required. Sequence[securityattribute.Get Security Attributes Security Attribute Validator] - Validates a security attribute value. Each validator performs validation steps in addition to the standard validation for security attribute values. For more information, see Limits on Security Attributes.
- compartment
Id This property is required. String - The OCID of the compartment that contains the security attribute definition.
- description
This property is required. String - The description you assign to the security attribute.
- id
This property is required. String - The OCID of the security attribute definition.
- is
Retired This property is required. Boolean - Indicates whether the security attribute is retired. See Managing Security Attribute Namespaces.
- name
This property is required. String - The name assigned to the security attribute during creation. This is the security attribute key. The name must be unique within the security attribute namespace and cannot be changed.
- security
Attribute Namespace Id This property is required. String - The OCID of the security attribute namespace.
- security
Attribute Namespace Name This property is required. String - The name of the security attribute namespace that contains the security attribute.
- state
This property is required. String - A filter to only return resources that match the given lifecycle state. The state value is case-insensitive.
- time
Created This property is required. String - Date and time the security attribute was created, in the format defined by RFC3339. Example:
2016-08-25T21:10:29.600Z
- type
This property is required. String - The data type of the security attribute.
- validators
This property is required. List<Property Map> - Validates a security attribute value. Each validator performs validation steps in addition to the standard validation for security attribute values. For more information, see Limits on Security Attributes.
GetSecurityAttributesSecurityAttributeValidator
- Validator
Type This property is required. string - Specifies the type of validation: a static value (no validation) or a list.
- Values
This property is required. List<string> - The list of allowed values for a security attribute value.
- Validator
Type This property is required. string - Specifies the type of validation: a static value (no validation) or a list.
- Values
This property is required. []string - The list of allowed values for a security attribute value.
- validator
Type This property is required. String - Specifies the type of validation: a static value (no validation) or a list.
- values
This property is required. List<String> - The list of allowed values for a security attribute value.
- validator
Type This property is required. string - Specifies the type of validation: a static value (no validation) or a list.
- values
This property is required. string[] - The list of allowed values for a security attribute value.
- validator_
type This property is required. str - Specifies the type of validation: a static value (no validation) or a list.
- values
This property is required. Sequence[str] - The list of allowed values for a security attribute value.
- validator
Type This property is required. String - Specifies the type of validation: a static value (no validation) or a list.
- values
This property is required. List<String> - The list of allowed values for a security attribute value.
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
oci
Terraform Provider.