1. Packages
  2. Azure Native
  3. API Docs
  4. security
  5. DeviceSecurityGroup
This is the latest version of Azure Native. Use the Azure Native v1 docs if using the v1 version of this package.
Azure Native v2.8.0 published on Monday, Sep 18, 2023 by Pulumi

azure-native.security.DeviceSecurityGroup

Explore with Pulumi AI

azure-native logo
This is the latest version of Azure Native. Use the Azure Native v1 docs if using the v1 version of this package.
Azure Native v2.8.0 published on Monday, Sep 18, 2023 by Pulumi

    The device security group resource Azure REST API version: 2019-08-01. Prior API version in Azure Native 1.x: 2019-08-01

    Example Usage

    Create or update a device security group for the specified IoT hub resource

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AzureNative = Pulumi.AzureNative;
    
    return await Deployment.RunAsync(() => 
    {
        var deviceSecurityGroup = new AzureNative.Security.DeviceSecurityGroup("deviceSecurityGroup", new()
        {
            DeviceSecurityGroupName = "samplesecuritygroup",
            ResourceId = "subscriptions/20ff7fc3-e762-44dd-bd96-b71116dcdc23/resourceGroups/SampleRG/providers/Microsoft.Devices/iotHubs/sampleiothub",
            TimeWindowRules = new[]
            {
                null,
            },
        });
    
    });
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-azure-native-sdk/security/v2"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := security.NewDeviceSecurityGroup(ctx, "deviceSecurityGroup", &security.DeviceSecurityGroupArgs{
    			DeviceSecurityGroupName: pulumi.String("samplesecuritygroup"),
    			ResourceId:              pulumi.String("subscriptions/20ff7fc3-e762-44dd-bd96-b71116dcdc23/resourceGroups/SampleRG/providers/Microsoft.Devices/iotHubs/sampleiothub"),
    			TimeWindowRules: []security.TimeWindowCustomAlertRuleArgs{
    				nil,
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.azurenative.security.DeviceSecurityGroup;
    import com.pulumi.azurenative.security.DeviceSecurityGroupArgs;
    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) {
            var deviceSecurityGroup = new DeviceSecurityGroup("deviceSecurityGroup", DeviceSecurityGroupArgs.builder()        
                .deviceSecurityGroupName("samplesecuritygroup")
                .resourceId("subscriptions/20ff7fc3-e762-44dd-bd96-b71116dcdc23/resourceGroups/SampleRG/providers/Microsoft.Devices/iotHubs/sampleiothub")
                .timeWindowRules()
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_azure_native as azure_native
    
    device_security_group = azure_native.security.DeviceSecurityGroup("deviceSecurityGroup",
        device_security_group_name="samplesecuritygroup",
        resource_id="subscriptions/20ff7fc3-e762-44dd-bd96-b71116dcdc23/resourceGroups/SampleRG/providers/Microsoft.Devices/iotHubs/sampleiothub",
        time_window_rules=[azure_native.security.TimeWindowCustomAlertRuleArgs()])
    
    import * as pulumi from "@pulumi/pulumi";
    import * as azure_native from "@pulumi/azure-native";
    
    const deviceSecurityGroup = new azure_native.security.DeviceSecurityGroup("deviceSecurityGroup", {
        deviceSecurityGroupName: "samplesecuritygroup",
        resourceId: "subscriptions/20ff7fc3-e762-44dd-bd96-b71116dcdc23/resourceGroups/SampleRG/providers/Microsoft.Devices/iotHubs/sampleiothub",
        timeWindowRules: [{}],
    });
    
    resources:
      deviceSecurityGroup:
        type: azure-native:security:DeviceSecurityGroup
        properties:
          deviceSecurityGroupName: samplesecuritygroup
          resourceId: subscriptions/20ff7fc3-e762-44dd-bd96-b71116dcdc23/resourceGroups/SampleRG/providers/Microsoft.Devices/iotHubs/sampleiothub
          timeWindowRules:
            - {}
    

    Create DeviceSecurityGroup Resource

    new DeviceSecurityGroup(name: string, args: DeviceSecurityGroupArgs, opts?: CustomResourceOptions);
    @overload
    def DeviceSecurityGroup(resource_name: str,
                            opts: Optional[ResourceOptions] = None,
                            allowlist_rules: Optional[Sequence[AllowlistCustomAlertRuleArgs]] = None,
                            denylist_rules: Optional[Sequence[DenylistCustomAlertRuleArgs]] = None,
                            device_security_group_name: Optional[str] = None,
                            resource_id: Optional[str] = None,
                            threshold_rules: Optional[Sequence[ThresholdCustomAlertRuleArgs]] = None,
                            time_window_rules: Optional[Sequence[TimeWindowCustomAlertRuleArgs]] = None)
    @overload
    def DeviceSecurityGroup(resource_name: str,
                            args: DeviceSecurityGroupArgs,
                            opts: Optional[ResourceOptions] = None)
    func NewDeviceSecurityGroup(ctx *Context, name string, args DeviceSecurityGroupArgs, opts ...ResourceOption) (*DeviceSecurityGroup, error)
    public DeviceSecurityGroup(string name, DeviceSecurityGroupArgs args, CustomResourceOptions? opts = null)
    public DeviceSecurityGroup(String name, DeviceSecurityGroupArgs args)
    public DeviceSecurityGroup(String name, DeviceSecurityGroupArgs args, CustomResourceOptions options)
    
    type: azure-native:security:DeviceSecurityGroup
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    name string
    The unique name of the resource.
    args DeviceSecurityGroupArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args DeviceSecurityGroupArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args DeviceSecurityGroupArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args DeviceSecurityGroupArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args DeviceSecurityGroupArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    DeviceSecurityGroup Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The DeviceSecurityGroup resource accepts the following input properties:

    ResourceId string

    The identifier of the resource.

    AllowlistRules List<Pulumi.AzureNative.Security.Inputs.AllowlistCustomAlertRule>

    The allow-list custom alert rules.

    DenylistRules List<Pulumi.AzureNative.Security.Inputs.DenylistCustomAlertRule>

    The deny-list custom alert rules.

    DeviceSecurityGroupName string

    The name of the device security group. Note that the name of the device security group is case insensitive.

    ThresholdRules List<Pulumi.AzureNative.Security.Inputs.ThresholdCustomAlertRule>

    The list of custom alert threshold rules.

    TimeWindowRules List<Pulumi.AzureNative.Security.Inputs.TimeWindowCustomAlertRule>

    The list of custom alert time-window rules.

    ResourceId string

    The identifier of the resource.

    AllowlistRules []AllowlistCustomAlertRuleArgs

    The allow-list custom alert rules.

    DenylistRules []DenylistCustomAlertRuleArgs

    The deny-list custom alert rules.

    DeviceSecurityGroupName string

    The name of the device security group. Note that the name of the device security group is case insensitive.

    ThresholdRules []ThresholdCustomAlertRuleArgs

    The list of custom alert threshold rules.

    TimeWindowRules []TimeWindowCustomAlertRuleArgs

    The list of custom alert time-window rules.

    resourceId String

    The identifier of the resource.

    allowlistRules List<AllowlistCustomAlertRule>

    The allow-list custom alert rules.

    denylistRules List<DenylistCustomAlertRule>

    The deny-list custom alert rules.

    deviceSecurityGroupName String

    The name of the device security group. Note that the name of the device security group is case insensitive.

    thresholdRules List<ThresholdCustomAlertRule>

    The list of custom alert threshold rules.

    timeWindowRules List<TimeWindowCustomAlertRule>

    The list of custom alert time-window rules.

    resourceId string

    The identifier of the resource.

    allowlistRules AllowlistCustomAlertRule[]

    The allow-list custom alert rules.

    denylistRules DenylistCustomAlertRule[]

    The deny-list custom alert rules.

    deviceSecurityGroupName string

    The name of the device security group. Note that the name of the device security group is case insensitive.

    thresholdRules ThresholdCustomAlertRule[]

    The list of custom alert threshold rules.

    timeWindowRules TimeWindowCustomAlertRule[]

    The list of custom alert time-window rules.

    resource_id str

    The identifier of the resource.

    allowlist_rules Sequence[AllowlistCustomAlertRuleArgs]

    The allow-list custom alert rules.

    denylist_rules Sequence[DenylistCustomAlertRuleArgs]

    The deny-list custom alert rules.

    device_security_group_name str

    The name of the device security group. Note that the name of the device security group is case insensitive.

    threshold_rules Sequence[ThresholdCustomAlertRuleArgs]

    The list of custom alert threshold rules.

    time_window_rules Sequence[TimeWindowCustomAlertRuleArgs]

    The list of custom alert time-window rules.

    resourceId String

    The identifier of the resource.

    allowlistRules List<Property Map>

    The allow-list custom alert rules.

    denylistRules List<Property Map>

    The deny-list custom alert rules.

    deviceSecurityGroupName String

    The name of the device security group. Note that the name of the device security group is case insensitive.

    thresholdRules List<Property Map>

    The list of custom alert threshold rules.

    timeWindowRules List<Property Map>

    The list of custom alert time-window rules.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the DeviceSecurityGroup resource produces the following output properties:

    Id string

    The provider-assigned unique ID for this managed resource.

    Name string

    Resource name

    Type string

    Resource type

    Id string

    The provider-assigned unique ID for this managed resource.

    Name string

    Resource name

    Type string

    Resource type

    id String

    The provider-assigned unique ID for this managed resource.

    name String

    Resource name

    type String

    Resource type

    id string

    The provider-assigned unique ID for this managed resource.

    name string

    Resource name

    type string

    Resource type

    id str

    The provider-assigned unique ID for this managed resource.

    name str

    Resource name

    type str

    Resource type

    id String

    The provider-assigned unique ID for this managed resource.

    name String

    Resource name

    type String

    Resource type

    Supporting Types

    AllowlistCustomAlertRule, AllowlistCustomAlertRuleArgs

    AllowlistValues List<string>

    The values to allow. The format of the values depends on the rule type.

    IsEnabled bool

    Status of the custom alert.

    AllowlistValues []string

    The values to allow. The format of the values depends on the rule type.

    IsEnabled bool

    Status of the custom alert.

    allowlistValues List<String>

    The values to allow. The format of the values depends on the rule type.

    isEnabled Boolean

    Status of the custom alert.

    allowlistValues string[]

    The values to allow. The format of the values depends on the rule type.

    isEnabled boolean

    Status of the custom alert.

    allowlist_values Sequence[str]

    The values to allow. The format of the values depends on the rule type.

    is_enabled bool

    Status of the custom alert.

    allowlistValues List<String>

    The values to allow. The format of the values depends on the rule type.

    isEnabled Boolean

    Status of the custom alert.

    AllowlistCustomAlertRuleResponse, AllowlistCustomAlertRuleResponseArgs

    AllowlistValues List<string>

    The values to allow. The format of the values depends on the rule type.

    Description string

    The description of the custom alert.

    DisplayName string

    The display name of the custom alert.

    IsEnabled bool

    Status of the custom alert.

    ValueType string

    The value type of the items in the list.

    AllowlistValues []string

    The values to allow. The format of the values depends on the rule type.

    Description string

    The description of the custom alert.

    DisplayName string

    The display name of the custom alert.

    IsEnabled bool

    Status of the custom alert.

    ValueType string

    The value type of the items in the list.

    allowlistValues List<String>

    The values to allow. The format of the values depends on the rule type.

    description String

    The description of the custom alert.

    displayName String

    The display name of the custom alert.

    isEnabled Boolean

    Status of the custom alert.

    valueType String

    The value type of the items in the list.

    allowlistValues string[]

    The values to allow. The format of the values depends on the rule type.

    description string

    The description of the custom alert.

    displayName string

    The display name of the custom alert.

    isEnabled boolean

    Status of the custom alert.

    valueType string

    The value type of the items in the list.

    allowlist_values Sequence[str]

    The values to allow. The format of the values depends on the rule type.

    description str

    The description of the custom alert.

    display_name str

    The display name of the custom alert.

    is_enabled bool

    Status of the custom alert.

    value_type str

    The value type of the items in the list.

    allowlistValues List<String>

    The values to allow. The format of the values depends on the rule type.

    description String

    The description of the custom alert.

    displayName String

    The display name of the custom alert.

    isEnabled Boolean

    Status of the custom alert.

    valueType String

    The value type of the items in the list.

    DenylistCustomAlertRule, DenylistCustomAlertRuleArgs

    DenylistValues List<string>

    The values to deny. The format of the values depends on the rule type.

    IsEnabled bool

    Status of the custom alert.

    DenylistValues []string

    The values to deny. The format of the values depends on the rule type.

    IsEnabled bool

    Status of the custom alert.

    denylistValues List<String>

    The values to deny. The format of the values depends on the rule type.

    isEnabled Boolean

    Status of the custom alert.

    denylistValues string[]

    The values to deny. The format of the values depends on the rule type.

    isEnabled boolean

    Status of the custom alert.

    denylist_values Sequence[str]

    The values to deny. The format of the values depends on the rule type.

    is_enabled bool

    Status of the custom alert.

    denylistValues List<String>

    The values to deny. The format of the values depends on the rule type.

    isEnabled Boolean

    Status of the custom alert.

    DenylistCustomAlertRuleResponse, DenylistCustomAlertRuleResponseArgs

    DenylistValues List<string>

    The values to deny. The format of the values depends on the rule type.

    Description string

    The description of the custom alert.

    DisplayName string

    The display name of the custom alert.

    IsEnabled bool

    Status of the custom alert.

    ValueType string

    The value type of the items in the list.

    DenylistValues []string

    The values to deny. The format of the values depends on the rule type.

    Description string

    The description of the custom alert.

    DisplayName string

    The display name of the custom alert.

    IsEnabled bool

    Status of the custom alert.

    ValueType string

    The value type of the items in the list.

    denylistValues List<String>

    The values to deny. The format of the values depends on the rule type.

    description String

    The description of the custom alert.

    displayName String

    The display name of the custom alert.

    isEnabled Boolean

    Status of the custom alert.

    valueType String

    The value type of the items in the list.

    denylistValues string[]

    The values to deny. The format of the values depends on the rule type.

    description string

    The description of the custom alert.

    displayName string

    The display name of the custom alert.

    isEnabled boolean

    Status of the custom alert.

    valueType string

    The value type of the items in the list.

    denylist_values Sequence[str]

    The values to deny. The format of the values depends on the rule type.

    description str

    The description of the custom alert.

    display_name str

    The display name of the custom alert.

    is_enabled bool

    Status of the custom alert.

    value_type str

    The value type of the items in the list.

    denylistValues List<String>

    The values to deny. The format of the values depends on the rule type.

    description String

    The description of the custom alert.

    displayName String

    The display name of the custom alert.

    isEnabled Boolean

    Status of the custom alert.

    valueType String

    The value type of the items in the list.

    ThresholdCustomAlertRule, ThresholdCustomAlertRuleArgs

    IsEnabled bool

    Status of the custom alert.

    MaxThreshold int

    The maximum threshold.

    MinThreshold int

    The minimum threshold.

    IsEnabled bool

    Status of the custom alert.

    MaxThreshold int

    The maximum threshold.

    MinThreshold int

    The minimum threshold.

    isEnabled Boolean

    Status of the custom alert.

    maxThreshold Integer

    The maximum threshold.

    minThreshold Integer

    The minimum threshold.

    isEnabled boolean

    Status of the custom alert.

    maxThreshold number

    The maximum threshold.

    minThreshold number

    The minimum threshold.

    is_enabled bool

    Status of the custom alert.

    max_threshold int

    The maximum threshold.

    min_threshold int

    The minimum threshold.

    isEnabled Boolean

    Status of the custom alert.

    maxThreshold Number

    The maximum threshold.

    minThreshold Number

    The minimum threshold.

    ThresholdCustomAlertRuleResponse, ThresholdCustomAlertRuleResponseArgs

    Description string

    The description of the custom alert.

    DisplayName string

    The display name of the custom alert.

    IsEnabled bool

    Status of the custom alert.

    MaxThreshold int

    The maximum threshold.

    MinThreshold int

    The minimum threshold.

    Description string

    The description of the custom alert.

    DisplayName string

    The display name of the custom alert.

    IsEnabled bool

    Status of the custom alert.

    MaxThreshold int

    The maximum threshold.

    MinThreshold int

    The minimum threshold.

    description String

    The description of the custom alert.

    displayName String

    The display name of the custom alert.

    isEnabled Boolean

    Status of the custom alert.

    maxThreshold Integer

    The maximum threshold.

    minThreshold Integer

    The minimum threshold.

    description string

    The description of the custom alert.

    displayName string

    The display name of the custom alert.

    isEnabled boolean

    Status of the custom alert.

    maxThreshold number

    The maximum threshold.

    minThreshold number

    The minimum threshold.

    description str

    The description of the custom alert.

    display_name str

    The display name of the custom alert.

    is_enabled bool

    Status of the custom alert.

    max_threshold int

    The maximum threshold.

    min_threshold int

    The minimum threshold.

    description String

    The description of the custom alert.

    displayName String

    The display name of the custom alert.

    isEnabled Boolean

    Status of the custom alert.

    maxThreshold Number

    The maximum threshold.

    minThreshold Number

    The minimum threshold.

    TimeWindowCustomAlertRule, TimeWindowCustomAlertRuleArgs

    IsEnabled bool

    Status of the custom alert.

    MaxThreshold int

    The maximum threshold.

    MinThreshold int

    The minimum threshold.

    TimeWindowSize string

    The time window size in iso8601 format.

    IsEnabled bool

    Status of the custom alert.

    MaxThreshold int

    The maximum threshold.

    MinThreshold int

    The minimum threshold.

    TimeWindowSize string

    The time window size in iso8601 format.

    isEnabled Boolean

    Status of the custom alert.

    maxThreshold Integer

    The maximum threshold.

    minThreshold Integer

    The minimum threshold.

    timeWindowSize String

    The time window size in iso8601 format.

    isEnabled boolean

    Status of the custom alert.

    maxThreshold number

    The maximum threshold.

    minThreshold number

    The minimum threshold.

    timeWindowSize string

    The time window size in iso8601 format.

    is_enabled bool

    Status of the custom alert.

    max_threshold int

    The maximum threshold.

    min_threshold int

    The minimum threshold.

    time_window_size str

    The time window size in iso8601 format.

    isEnabled Boolean

    Status of the custom alert.

    maxThreshold Number

    The maximum threshold.

    minThreshold Number

    The minimum threshold.

    timeWindowSize String

    The time window size in iso8601 format.

    TimeWindowCustomAlertRuleResponse, TimeWindowCustomAlertRuleResponseArgs

    Description string

    The description of the custom alert.

    DisplayName string

    The display name of the custom alert.

    IsEnabled bool

    Status of the custom alert.

    MaxThreshold int

    The maximum threshold.

    MinThreshold int

    The minimum threshold.

    TimeWindowSize string

    The time window size in iso8601 format.

    Description string

    The description of the custom alert.

    DisplayName string

    The display name of the custom alert.

    IsEnabled bool

    Status of the custom alert.

    MaxThreshold int

    The maximum threshold.

    MinThreshold int

    The minimum threshold.

    TimeWindowSize string

    The time window size in iso8601 format.

    description String

    The description of the custom alert.

    displayName String

    The display name of the custom alert.

    isEnabled Boolean

    Status of the custom alert.

    maxThreshold Integer

    The maximum threshold.

    minThreshold Integer

    The minimum threshold.

    timeWindowSize String

    The time window size in iso8601 format.

    description string

    The description of the custom alert.

    displayName string

    The display name of the custom alert.

    isEnabled boolean

    Status of the custom alert.

    maxThreshold number

    The maximum threshold.

    minThreshold number

    The minimum threshold.

    timeWindowSize string

    The time window size in iso8601 format.

    description str

    The description of the custom alert.

    display_name str

    The display name of the custom alert.

    is_enabled bool

    Status of the custom alert.

    max_threshold int

    The maximum threshold.

    min_threshold int

    The minimum threshold.

    time_window_size str

    The time window size in iso8601 format.

    description String

    The description of the custom alert.

    displayName String

    The display name of the custom alert.

    isEnabled Boolean

    Status of the custom alert.

    maxThreshold Number

    The maximum threshold.

    minThreshold Number

    The minimum threshold.

    timeWindowSize String

    The time window size in iso8601 format.

    Import

    An existing resource can be imported using its type token, name, and identifier, e.g.

    $ pulumi import azure-native:security:DeviceSecurityGroup samplesecuritygroup /{resourceId}/providers/Microsoft.Security/deviceSecurityGroups/{deviceSecurityGroupName} 
    

    Package Details

    Repository
    Azure Native pulumi/pulumi-azure-native
    License
    Apache-2.0
    azure-native logo
    This is the latest version of Azure Native. Use the Azure Native v1 docs if using the v1 version of this package.
    Azure Native v2.8.0 published on Monday, Sep 18, 2023 by Pulumi