ContentKeyPolicy

Manages a Content Key Policy.

Example Usage

using System.Collections.Generic;
using System.Text.Json;
using Pulumi;
using Azure = Pulumi.Azure;

return await Deployment.RunAsync(() => 
{
    var exampleResourceGroup = new Azure.Core.ResourceGroup("exampleResourceGroup", new()
    {
        Location = "West Europe",
    });

    var exampleAccount = new Azure.Storage.Account("exampleAccount", new()
    {
        ResourceGroupName = exampleResourceGroup.Name,
        Location = exampleResourceGroup.Location,
        AccountTier = "Standard",
        AccountReplicationType = "GRS",
    });

    var exampleServiceAccount = new Azure.Media.ServiceAccount("exampleServiceAccount", new()
    {
        Location = exampleResourceGroup.Location,
        ResourceGroupName = exampleResourceGroup.Name,
        StorageAccounts = new[]
        {
            new Azure.Media.Inputs.ServiceAccountStorageAccountArgs
            {
                Id = exampleAccount.Id,
                IsPrimary = true,
            },
        },
    });

    var exampleContentKeyPolicy = new Azure.Media.ContentKeyPolicy("exampleContentKeyPolicy", new()
    {
        ResourceGroupName = exampleResourceGroup.Name,
        MediaServicesAccountName = exampleServiceAccount.Name,
        PolicyOptions = new[]
        {
            new Azure.Media.Inputs.ContentKeyPolicyPolicyOptionArgs
            {
                Name = "fairPlay",
                FairplayConfiguration = new Azure.Media.Inputs.ContentKeyPolicyPolicyOptionFairplayConfigurationArgs
                {
                    Ask = "bb566284cc124a21c435a92cd3c108c4",
                    Pfx = "MIIG7gIBAzCCBqoGCSqGSIb3DQEHAaCCBpsEggaXMIIGkzCCA7wGCSqGSIb3DQEHAaCCA60EggOpMIIDpTCCA6EGCyqGSIb3DQEMCgECoIICtjCCArIwHAYKKoZIhvcNAQwBAzAOBAiV65vFfxLDVgICB9AEggKQx2dxWefICYodVhRLSQVMJRYy5QkM1VySPAXGP744JHrb+s0Y8i/6a+a5itZGlXw3kvxyflHtSsuuBCaYJ1WOCp9jspixJEliFHXTcel96AgZlT5tB7vC6pdZnz8rb+lyxFs99x2CW52EsadoDlRsYrmkmKdnB0cx2JHJbLeXuKV/fjuRJSqCFcDa6Nre8AlB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iPSGg5axP4JM+GmiVEqOHTVAPw2AM8OPnn1q0mIw54oC2WOJw3FFThYHmxTQzQ1feVmnkVCv++eFp+BYTcWTa+ehl/3/Nvr5uLTzDxmCShacKwoWXOKtSLh6mmgydvMqSf6xv1bPsloodtrRxhprI2lBNBW2uw8az9eLdvURYmhjGPf9klEy/6OCA5jDT5XZMunwiQT5mYNMF7wAQ5PCz2dJQqm1n72A6nUHPkHEusN7iH/+mv5d3iaKxn7/ShxLKHfjMd+r/gv27ylshVHiN4mVStAg+MiLrVvr5VH46p6oosImvS3ZO4D5wTmh/6wtus803qN4QB/Y9n4rqEJ4Dn619h+6O7FChzWkx7kvYIzIxvfnj1PCFTEjUwc7jbuF013W/z9zQi2YEq9AzxMcGro0zjdt2sf30zXSfaRNt0UHHRDkLo7yFUJG5Ka1uWU8paLuXUUiiMUf24Bsfdg2A2n+3Qa7g25OvAM1QTpMwmMWL9sY2hxVUGIKVrnj8c4EKuGJjVDXrze5g9O/LfZr5VSjGu5KsN0eYI3mcePF7XM0azMtTNQYVRmeWxYW+XvK5MaoLEkrFG8C5+JccIlN588jowVIPqP321S/EyFiAmrRdAWkqrc9KH+/eINCFqjut2YPkCaTM9mnJAAqWgggUWkrOKT/ByS6IAQwyEBNFbY0TWyxKt6vZL1EW/6HgZCsxeYycNhnPr2qJNZZMNzmdMRp2GRLcfBH8KFw1rAyua0VJoTLHb23ZAsEY74BrEEiK9e/oOjXkHzQjlmrfQ9rSN2eQpRrn0W8I229WmBO2suG+AQ3aY8kDtBMkjmJno7txUh1K5D6tJTO7MQp343A2AhyJkhYA7NPnDA7MB8wBwYFKw4DAhoEFPO82HDlCzlshWlnMoQPStm62TMEBBQsPmvwbZ5OlwC9+NDF1AC+t67WTgICB9A=",
                    PfxPassword = "password",
                    RentalDurationSeconds = 2249,
                    RentalAndLeaseKeyType = "PersistentUnlimited",
                },
                OpenRestrictionEnabled = true,
            },
            new Azure.Media.Inputs.ContentKeyPolicyPolicyOptionArgs
            {
                Name = "playReady",
                PlayreadyConfigurationLicenses = new[]
                {
                    new Azure.Media.Inputs.ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicenseArgs
                    {
                        AllowTestDevices = true,
                        BeginDate = "2017-10-16T18:22:53Z",
                        PlayRight = new Azure.Media.Inputs.ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicensePlayRightArgs
                        {
                            ScmsRestriction = 2,
                            DigitalVideoOnlyContentRestriction = false,
                            ImageConstraintForAnalogComponentVideoRestriction = false,
                            ImageConstraintForAnalogComputerMonitorRestriction = false,
                            AllowPassingVideoContentToUnknownOutput = "NotAllowed",
                            UncompressedDigitalVideoOpl = 100,
                            UncompressedDigitalAudioOpl = 100,
                            AnalogVideoOpl = 150,
                            CompressedDigitalAudioOpl = 150,
                        },
                        LicenseType = "Persistent",
                        ContentType = "UltraVioletDownload",
                        ContentKeyLocationFromHeaderEnabled = true,
                    },
                },
                OpenRestrictionEnabled = true,
            },
            new Azure.Media.Inputs.ContentKeyPolicyPolicyOptionArgs
            {
                Name = "clearKey",
                ClearKeyConfigurationEnabled = true,
                TokenRestriction = new Azure.Media.Inputs.ContentKeyPolicyPolicyOptionTokenRestrictionArgs
                {
                    Issuer = "urn:issuer",
                    Audience = "urn:audience",
                    TokenType = "Swt",
                    PrimarySymmetricTokenKey = "AAAAAAAAAAAAAAAAAAAAAA==",
                },
            },
            new Azure.Media.Inputs.ContentKeyPolicyPolicyOptionArgs
            {
                Name = "widevine",
                WidevineConfigurationTemplate = JsonSerializer.Serialize(new Dictionary<string, object?>
                {
                    ["allowed_track_types"] = "SD_HD",
                    ["content_key_specs"] = new[]
                    {
                        new Dictionary<string, object?>
                        {
                            ["track_type"] = "SD",
                            ["security_level"] = 1,
                            ["required_output_protection"] = new Dictionary<string, object?>
                            {
                                ["hdcp"] = "HDCP_V2",
                            },
                        },
                    },
                    ["policy_overrides"] = new Dictionary<string, object?>
                    {
                        ["can_play"] = true,
                        ["can_persist"] = true,
                        ["can_renew"] = false,
                    },
                }),
                OpenRestrictionEnabled = true,
            },
        },
    });

});
package main

import (
	"encoding/json"

	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/media"
	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/storage"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		exampleResourceGroup, err := core.NewResourceGroup(ctx, "exampleResourceGroup", &core.ResourceGroupArgs{
			Location: pulumi.String("West Europe"),
		})
		if err != nil {
			return err
		}
		exampleAccount, err := storage.NewAccount(ctx, "exampleAccount", &storage.AccountArgs{
			ResourceGroupName:      exampleResourceGroup.Name,
			Location:               exampleResourceGroup.Location,
			AccountTier:            pulumi.String("Standard"),
			AccountReplicationType: pulumi.String("GRS"),
		})
		if err != nil {
			return err
		}
		exampleServiceAccount, err := media.NewServiceAccount(ctx, "exampleServiceAccount", &media.ServiceAccountArgs{
			Location:          exampleResourceGroup.Location,
			ResourceGroupName: exampleResourceGroup.Name,
			StorageAccounts: media.ServiceAccountStorageAccountArray{
				&media.ServiceAccountStorageAccountArgs{
					Id:        exampleAccount.ID(),
					IsPrimary: pulumi.Bool(true),
				},
			},
		})
		if err != nil {
			return err
		}
		tmpJSON0, err := json.Marshal(map[string]interface{}{
			"allowed_track_types": "SD_HD",
			"content_key_specs": []map[string]interface{}{
				map[string]interface{}{
					"track_type":     "SD",
					"security_level": 1,
					"required_output_protection": map[string]interface{}{
						"hdcp": "HDCP_V2",
					},
				},
			},
			"policy_overrides": map[string]interface{}{
				"can_play":    true,
				"can_persist": true,
				"can_renew":   false,
			},
		})
		if err != nil {
			return err
		}
		json0 := string(tmpJSON0)
		_, err = media.NewContentKeyPolicy(ctx, "exampleContentKeyPolicy", &media.ContentKeyPolicyArgs{
			ResourceGroupName:        exampleResourceGroup.Name,
			MediaServicesAccountName: exampleServiceAccount.Name,
			PolicyOptions: media.ContentKeyPolicyPolicyOptionArray{
				&media.ContentKeyPolicyPolicyOptionArgs{
					Name: pulumi.String("fairPlay"),
					FairplayConfiguration: &media.ContentKeyPolicyPolicyOptionFairplayConfigurationArgs{
						Ask:                   pulumi.String("bb566284cc124a21c435a92cd3c108c4"),
						Pfx:                   pulumi.String("MIIG7gIBAzCCBqoGCSqGSIb3DQEHAaCCBpsEggaXMIIGkzCCA7wGCSqGSIb3DQEHAaCCA60EggOpMIIDpTCCA6EGCyqGSIb3DQEMCgECoIICtjCCArIwHAYKKoZIhvcNAQwBAzAOBAiV65vFfxLDVgICB9AEggKQx2dxWefICYodVhRLSQVMJRYy5QkM1VySPAXGP744JHrb+s0Y8i/6a+a5itZGlXw3kvxyflHtSsuuBCaYJ1WOCp9jspixJEliFHXTcel96AgZlT5tB7vC6pdZnz8rb+lyxFs99x2CW52EsadoDlRsYrmkmKdnB0cx2JHJbLeXuKV/fjuRJSqCFcDa6Nre8AlBX0zKGIYGLJ1Cfpora4kNTXxu0AwEowzGmoCxqrpKbO1QDi1hZ1qHrtZ1ienAKfiTXaGH4AMQzyut0AaymxalrRbXibJYuefLRvXqx0oLZKVLAX8fR1gnac6Mrr7GkdHaKCsk4eOi98acR7bjiyRRVYYS4B6Y0tCeRJNe6zeYVmLdtatuOlOEVDT6AKrJJMFMyITVS+2D771ge6m37FbJ36K3/eT/HRq1YDsxfD/BY+X7eMIwQrVnD5nK7avXfbIni57n5oWLkE9Vco8uBlMdrx4xHt9vpe42Pz2Yh2O4WtvxcgxrAknvPpV1ZsAJCfvm9TTcg8qZpjyePn3B9TvFVSXMJHn/rzu6OJAgFgVFAe1tPGLh1XBxAvwpB8EqcycIIUUFUBy4HgYCicjI2jp6s8Kk293Uc/TA2623LrWgP/Xm5hVB7lP1k6W9LDivOlAA96D0Cbk08Yv6arkCYj7ONFO8VZbO0zKAAOLHMw/ZQRIutGLrDlqgTDeRXRuReX7TNjDBxp2rzJBY0uU5g9BMFxQrbQwEx9HsnO4dVFG4KLbHmYWhlwS2V2uZt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aoLEkrFG8C5+JccIlN588jowVIPqP321S/EyFiAmrRdAWkqrc9KH+/eINCFqjut2YPkCaTM9mnJAAqWgggUWkrOKT/ByS6IAQwyEBNFbY0TWyxKt6vZL1EW/6HgZCsxeYycNhnPr2qJNZZMNzmdMRp2GRLcfBH8KFw1rAyua0VJoTLHb23ZAsEY74BrEEiK9e/oOjXkHzQjlmrfQ9rSN2eQpRrn0W8I229WmBO2suG+AQ3aY8kDtBMkjmJno7txUh1K5D6tJTO7MQp343A2AhyJkhYA7NPnDA7MB8wBwYFKw4DAhoEFPO82HDlCzlshWlnMoQPStm62TMEBBQsPmvwbZ5OlwC9+NDF1AC+t67WTgICB9A="),
						PfxPassword:           pulumi.String("password"),
						RentalDurationSeconds: pulumi.Int(2249),
						RentalAndLeaseKeyType: pulumi.String("PersistentUnlimited"),
					},
					OpenRestrictionEnabled: pulumi.Bool(true),
				},
				&media.ContentKeyPolicyPolicyOptionArgs{
					Name: pulumi.String("playReady"),
					PlayreadyConfigurationLicenses: media.ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicenseArray{
						&media.ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicenseArgs{
							AllowTestDevices: pulumi.Bool(true),
							BeginDate:        pulumi.String("2017-10-16T18:22:53Z"),
							PlayRight: &media.ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicensePlayRightArgs{
								ScmsRestriction:                                    pulumi.Int(2),
								DigitalVideoOnlyContentRestriction:                 pulumi.Bool(false),
								ImageConstraintForAnalogComponentVideoRestriction:  pulumi.Bool(false),
								ImageConstraintForAnalogComputerMonitorRestriction: pulumi.Bool(false),
								AllowPassingVideoContentToUnknownOutput:            pulumi.String("NotAllowed"),
								UncompressedDigitalVideoOpl:                        pulumi.Int(100),
								UncompressedDigitalAudioOpl:                        pulumi.Int(100),
								AnalogVideoOpl:                                     pulumi.Int(150),
								CompressedDigitalAudioOpl:                          pulumi.Int(150),
							},
							LicenseType:                         pulumi.String("Persistent"),
							ContentType:                         pulumi.String("UltraVioletDownload"),
							ContentKeyLocationFromHeaderEnabled: pulumi.Bool(true),
						},
					},
					OpenRestrictionEnabled: pulumi.Bool(true),
				},
				&media.ContentKeyPolicyPolicyOptionArgs{
					Name:                         pulumi.String("clearKey"),
					ClearKeyConfigurationEnabled: pulumi.Bool(true),
					TokenRestriction: &media.ContentKeyPolicyPolicyOptionTokenRestrictionArgs{
						Issuer:                   pulumi.String("urn:issuer"),
						Audience:                 pulumi.String("urn:audience"),
						TokenType:                pulumi.String("Swt"),
						PrimarySymmetricTokenKey: pulumi.String("AAAAAAAAAAAAAAAAAAAAAA=="),
					},
				},
				&media.ContentKeyPolicyPolicyOptionArgs{
					Name:                          pulumi.String("widevine"),
					WidevineConfigurationTemplate: pulumi.String(json0),
					OpenRestrictionEnabled:        pulumi.Bool(true),
				},
			},
		})
		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.azure.core.ResourceGroup;
import com.pulumi.azure.core.ResourceGroupArgs;
import com.pulumi.azure.storage.Account;
import com.pulumi.azure.storage.AccountArgs;
import com.pulumi.azure.media.ServiceAccount;
import com.pulumi.azure.media.ServiceAccountArgs;
import com.pulumi.azure.media.inputs.ServiceAccountStorageAccountArgs;
import com.pulumi.azure.media.ContentKeyPolicy;
import com.pulumi.azure.media.ContentKeyPolicyArgs;
import com.pulumi.azure.media.inputs.ContentKeyPolicyPolicyOptionArgs;
import com.pulumi.azure.media.inputs.ContentKeyPolicyPolicyOptionFairplayConfigurationArgs;
import com.pulumi.azure.media.inputs.ContentKeyPolicyPolicyOptionTokenRestrictionArgs;
import static com.pulumi.codegen.internal.Serialization.*;
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 exampleResourceGroup = new ResourceGroup("exampleResourceGroup", ResourceGroupArgs.builder()        
            .location("West Europe")
            .build());

        var exampleAccount = new Account("exampleAccount", AccountArgs.builder()        
            .resourceGroupName(exampleResourceGroup.name())
            .location(exampleResourceGroup.location())
            .accountTier("Standard")
            .accountReplicationType("GRS")
            .build());

        var exampleServiceAccount = new ServiceAccount("exampleServiceAccount", ServiceAccountArgs.builder()        
            .location(exampleResourceGroup.location())
            .resourceGroupName(exampleResourceGroup.name())
            .storageAccounts(ServiceAccountStorageAccountArgs.builder()
                .id(exampleAccount.id())
                .isPrimary(true)
                .build())
            .build());

        var exampleContentKeyPolicy = new ContentKeyPolicy("exampleContentKeyPolicy", ContentKeyPolicyArgs.builder()        
            .resourceGroupName(exampleResourceGroup.name())
            .mediaServicesAccountName(exampleServiceAccount.name())
            .policyOptions(            
                ContentKeyPolicyPolicyOptionArgs.builder()
                    .name("fairPlay")
                    .fairplayConfiguration(ContentKeyPolicyPolicyOptionFairplayConfigurationArgs.builder()
                        .ask("bb566284cc124a21c435a92cd3c108c4")
                        .pfx("MIIG7gIBAzCCBqoGCSqGSIb3DQEHAaCCBpsEggaXMIIGkzCCA7wGCSqGSIb3DQEHAaCCA60EggOpMIIDpTCCA6EGCyqGSIb3DQEMCgECoIICtjCCArIwHAYKKoZIhvcNAQwBAzAOBAiV65vFfxLDVgICB9AEggKQx2dxWefICYodVhRLSQVMJRYy5QkM1VySPAXGP744JHrb+s0Y8i/6a+a5itZGlXw3kvxyflHtSsuuBCaYJ1WOCp9jspixJEliFHXTcel96AgZlT5tB7vC6pdZnz8rb+lyxFs99x2CW52EsadoDlRsYrmkmKdnB0cx2JHJbLeXuKV/fjuRJSqCFcDa6Nre8AlBX0zKGIYGLJ1Cfpora4kNTXxu0AwEowzGmoCxqrpKbO1QDi1hZ1qHrtZ1ienAKfiTXaGH4AMQzyut0AaymxalrRbXibJYuefLRvXqx0oLZKVLAX8fR1gnac6Mrr7GkdHaKCsk4eOi98acR7bjiyRRVYYS4B6Y0tCeRJNe6zeYVmLdt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y/6OCA5jDT5XZMunwiQT5mYNMF7wAQ5PCz2dJQqm1n72A6nUHPkHEusN7iH/+mv5d3iaKxn7/ShxLKHfjMd+r/gv27ylshVHiN4mVStAg+MiLrVvr5VH46p6oosImvS3ZO4D5wTmh/6wtus803qN4QB/Y9n4rqEJ4Dn619h+6O7FChzWkx7kvYIzIxvfnj1PCFTEjUwc7jbuF013W/z9zQi2YEq9AzxMcGro0zjdt2sf30zXSfaRNt0UHHRDkLo7yFUJG5Ka1uWU8paLuXUUiiMUf24Bsfdg2A2n+3Qa7g25OvAM1QTpMwmMWL9sY2hxVUGIKVrnj8c4EKuGJjVDXrze5g9O/LfZr5VSjGu5KsN0eYI3mcePF7XM0azMtTNQYVRmeWxYW+XvK5MaoLEkrFG8C5+JccIlN588jowVIPqP321S/EyFiAmrRdAWkqrc9KH+/eINCFqjut2YPkCaTM9mnJAAqWgggUWkrOKT/ByS6IAQwyEBNFbY0TWyxKt6vZL1EW/6HgZCsxeYycNhnPr2qJNZZMNzmdMRp2GRLcfBH8KFw1rAyua0VJoTLHb23ZAsEY74BrEEiK9e/oOjXkHzQjlmrfQ9rSN2eQpRrn0W8I229WmBO2suG+AQ3aY8kDtBMkjmJno7txUh1K5D6tJTO7MQp343A2AhyJkhYA7NPnDA7MB8wBwYFKw4DAhoEFPO82HDlCzlshWlnMoQPStm62TMEBBQsPmvwbZ5OlwC9+NDF1AC+t67WTgICB9A=")
                        .pfxPassword("password")
                        .rentalDurationSeconds(2249)
                        .rentalAndLeaseKeyType("PersistentUnlimited")
                        .build())
                    .openRestrictionEnabled(true)
                    .build(),
                ContentKeyPolicyPolicyOptionArgs.builder()
                    .name("playReady")
                    .playreadyConfigurationLicenses(ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicenseArgs.builder()
                        .allowTestDevices(true)
                        .beginDate("2017-10-16T18:22:53Z")
                        .playRight(ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicensePlayRightArgs.builder()
                            .scmsRestriction(2)
                            .digitalVideoOnlyContentRestriction(false)
                            .imageConstraintForAnalogComponentVideoRestriction(false)
                            .imageConstraintForAnalogComputerMonitorRestriction(false)
                            .allowPassingVideoContentToUnknownOutput("NotAllowed")
                            .uncompressedDigitalVideoOpl(100)
                            .uncompressedDigitalAudioOpl(100)
                            .analogVideoOpl(150)
                            .compressedDigitalAudioOpl(150)
                            .build())
                        .licenseType("Persistent")
                        .contentType("UltraVioletDownload")
                        .contentKeyLocationFromHeaderEnabled(true)
                        .build())
                    .openRestrictionEnabled(true)
                    .build(),
                ContentKeyPolicyPolicyOptionArgs.builder()
                    .name("clearKey")
                    .clearKeyConfigurationEnabled(true)
                    .tokenRestriction(ContentKeyPolicyPolicyOptionTokenRestrictionArgs.builder()
                        .issuer("urn:issuer")
                        .audience("urn:audience")
                        .tokenType("Swt")
                        .primarySymmetricTokenKey("AAAAAAAAAAAAAAAAAAAAAA==")
                        .build())
                    .build(),
                ContentKeyPolicyPolicyOptionArgs.builder()
                    .name("widevine")
                    .widevineConfigurationTemplate(serializeJson(
                        jsonObject(
                            jsonProperty("allowed_track_types", "SD_HD"),
                            jsonProperty("content_key_specs", jsonArray(jsonObject(
                                jsonProperty("track_type", "SD"),
                                jsonProperty("security_level", 1),
                                jsonProperty("required_output_protection", jsonObject(
                                    jsonProperty("hdcp", "HDCP_V2")
                                ))
                            ))),
                            jsonProperty("policy_overrides", jsonObject(
                                jsonProperty("can_play", true),
                                jsonProperty("can_persist", true),
                                jsonProperty("can_renew", false)
                            ))
                        )))
                    .openRestrictionEnabled(true)
                    .build())
            .build());

    }
}
import pulumi
import json
import pulumi_azure as azure

example_resource_group = azure.core.ResourceGroup("exampleResourceGroup", location="West Europe")
example_account = azure.storage.Account("exampleAccount",
    resource_group_name=example_resource_group.name,
    location=example_resource_group.location,
    account_tier="Standard",
    account_replication_type="GRS")
example_service_account = azure.media.ServiceAccount("exampleServiceAccount",
    location=example_resource_group.location,
    resource_group_name=example_resource_group.name,
    storage_accounts=[azure.media.ServiceAccountStorageAccountArgs(
        id=example_account.id,
        is_primary=True,
    )])
example_content_key_policy = azure.media.ContentKeyPolicy("exampleContentKeyPolicy",
    resource_group_name=example_resource_group.name,
    media_services_account_name=example_service_account.name,
    policy_options=[
        azure.media.ContentKeyPolicyPolicyOptionArgs(
            name="fairPlay",
            fairplay_configuration=azure.media.ContentKeyPolicyPolicyOptionFairplayConfigurationArgs(
                ask="bb566284cc124a21c435a92cd3c108c4",
                pfx="MIIG7gIBAzCCBqoGCSqGSIb3DQEHAaCCBpsEggaXMIIGkzCCA7wGCSqGSIb3DQEHAaCCA60EggOpMIIDpTCCA6EGCyqGSIb3DQEMCgECoIICtjCCArIwHAYKKoZIhvcNAQwBAzAOBAiV65vFfxLDVgICB9AEggKQx2dxWefICYodVhRLSQVMJRYy5QkM1VySPAXGP744JHrb+s0Y8i/6a+a5itZGlXw3kvxyflHtSsuuBCaYJ1WOCp9jspixJEliFHXTcel96AgZlT5tB7vC6pdZnz8rb+lyxFs99x2CW52EsadoDlRsYrmkmKdnB0cx2JHJbLeXuKV/fjuRJSqCFcDa6Nre8AlBX0zKGIYGLJ1Cfpora4kNTXxu0AwEowzGmoCxqrpKbO1QDi1hZ1qHrtZ1ienAKfiTXaGH4AMQzyut0AaymxalrRbXibJYuefLRvXqx0oLZKVLAX8fR1gnac6Mrr7GkdHaKCsk4eOi98acR7bjiyRRVYYS4B6Y0tCeRJNe6zeYVmLdtatuOlOEVDT6AKrJJMFMyITVS+2D771ge6m37FbJ36K3/eT/HRq1YDsxfD/BY+X7eMIwQrVnD5nK7avXfbIni57n5oWLkE9Vco8uBlMdrx4xHt9vpe42Pz2Yh2O4WtvxcgxrAknvPpV1ZsAJCfvm9TTcg8qZpjyePn3B9TvFVSXMJHn/rzu6OJAgFgVFAe1tPGLh1XBxAvwpB8EqcycIIUUFUBy4HgYCicjI2jp6s8Kk293Uc/TA2623LrWgP/Xm5hVB7lP1k6W9LDivOlAA96D0Cbk08Yv6arkCYj7ONFO8VZbO0zKAAOL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MWL9sY2hxVUGIKVrnj8c4EKuGJjVDXrze5g9O/LfZr5VSjGu5KsN0eYI3mcePF7XM0azMtTNQYVRmeWxYW+XvK5MaoLEkrFG8C5+JccIlN588jowVIPqP321S/EyFiAmrRdAWkqrc9KH+/eINCFqjut2YPkCaTM9mnJAAqWgggUWkrOKT/ByS6IAQwyEBNFbY0TWyxKt6vZL1EW/6HgZCsxeYycNhnPr2qJNZZMNzmdMRp2GRLcfBH8KFw1rAyua0VJoTLHb23ZAsEY74BrEEiK9e/oOjXkHzQjlmrfQ9rSN2eQpRrn0W8I229WmBO2suG+AQ3aY8kDtBMkjmJno7txUh1K5D6tJTO7MQp343A2AhyJkhYA7NPnDA7MB8wBwYFKw4DAhoEFPO82HDlCzlshWlnMoQPStm62TMEBBQsPmvwbZ5OlwC9+NDF1AC+t67WTgICB9A=",
                pfx_password="password",
                rental_duration_seconds=2249,
                rental_and_lease_key_type="PersistentUnlimited",
            ),
            open_restriction_enabled=True,
        ),
        azure.media.ContentKeyPolicyPolicyOptionArgs(
            name="playReady",
            playready_configuration_licenses=[azure.media.ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicenseArgs(
                allow_test_devices=True,
                begin_date="2017-10-16T18:22:53Z",
                play_right=azure.media.ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicensePlayRightArgs(
                    scms_restriction=2,
                    digital_video_only_content_restriction=False,
                    image_constraint_for_analog_component_video_restriction=False,
                    image_constraint_for_analog_computer_monitor_restriction=False,
                    allow_passing_video_content_to_unknown_output="NotAllowed",
                    uncompressed_digital_video_opl=100,
                    uncompressed_digital_audio_opl=100,
                    analog_video_opl=150,
                    compressed_digital_audio_opl=150,
                ),
                license_type="Persistent",
                content_type="UltraVioletDownload",
                content_key_location_from_header_enabled=True,
            )],
            open_restriction_enabled=True,
        ),
        azure.media.ContentKeyPolicyPolicyOptionArgs(
            name="clearKey",
            clear_key_configuration_enabled=True,
            token_restriction=azure.media.ContentKeyPolicyPolicyOptionTokenRestrictionArgs(
                issuer="urn:issuer",
                audience="urn:audience",
                token_type="Swt",
                primary_symmetric_token_key="AAAAAAAAAAAAAAAAAAAAAA==",
            ),
        ),
        azure.media.ContentKeyPolicyPolicyOptionArgs(
            name="widevine",
            widevine_configuration_template=json.dumps({
                "allowed_track_types": "SD_HD",
                "content_key_specs": [{
                    "track_type": "SD",
                    "security_level": 1,
                    "required_output_protection": {
                        "hdcp": "HDCP_V2",
                    },
                }],
                "policy_overrides": {
                    "can_play": True,
                    "can_persist": True,
                    "can_renew": False,
                },
            }),
            open_restriction_enabled=True,
        ),
    ])
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";

const exampleResourceGroup = new azure.core.ResourceGroup("exampleResourceGroup", {location: "West Europe"});
const exampleAccount = new azure.storage.Account("exampleAccount", {
    resourceGroupName: exampleResourceGroup.name,
    location: exampleResourceGroup.location,
    accountTier: "Standard",
    accountReplicationType: "GRS",
});
const exampleServiceAccount = new azure.media.ServiceAccount("exampleServiceAccount", {
    location: exampleResourceGroup.location,
    resourceGroupName: exampleResourceGroup.name,
    storageAccounts: [{
        id: exampleAccount.id,
        isPrimary: true,
    }],
});
const exampleContentKeyPolicy = new azure.media.ContentKeyPolicy("exampleContentKeyPolicy", {
    resourceGroupName: exampleResourceGroup.name,
    mediaServicesAccountName: exampleServiceAccount.name,
    policyOptions: [
        {
            name: "fairPlay",
            fairplayConfiguration: {
                ask: "bb566284cc124a21c435a92cd3c108c4",
                pfx: "MIIG7gIBAzCCBqoGCSqGSIb3DQEHAaCCBpsEggaXMIIGkzCCA7wGCSqGSIb3DQEHAaCCA60EggOpMIIDpTCCA6EGCyqGSIb3DQEMCgECoIICtjCCArIwHAYKKoZIhvcNAQwBAzAOBAiV65vFfxLDVgICB9AEggKQx2dxWefICYodVhRLSQVMJRYy5QkM1VySPAXGP744JHrb+s0Y8i/6a+a5itZGlXw3kvxyflHtSsuuBCaYJ1WOCp9jspixJEliFHXTcel96AgZlT5tB7vC6pdZnz8rb+ly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AMIICtQYJKoZIhvcNAQcBMBwGCiqGSIb3DQEMAQMwDgQISS7mG/riQJkCAgfQgIICiPSGg5axP4JM+GmiVEqOHTVAPw2AM8OPnn1q0mIw54oC2WOJw3FFThYHmxTQzQ1feVmnkVCv++eFp+BYTcWTa+ehl/3/Nvr5uLTzDxmCShacKwoWXOKtSLh6mmgydvMqSf6xv1bPsloodtrRxhprI2lBNBW2uw8az9eLdvURYmhjGPf9klEy/6OCA5jDT5XZMunwiQT5mYNMF7wAQ5PCz2dJQqm1n72A6nUHPkHEusN7iH/+mv5d3iaKxn7/ShxLKHfjMd+r/gv27ylshVHiN4mVStAg+MiLrVvr5VH46p6oosImvS3ZO4D5wTmh/6wtus803qN4QB/Y9n4rqEJ4Dn619h+6O7FChzWkx7kvYIzIxvfnj1PCFTEjUwc7jbuF013W/z9zQi2YEq9AzxMcGro0zjdt2sf30zXSfaRNt0UHHRDkLo7yFUJG5Ka1uWU8paLuXUUiiMUf24Bsfdg2A2n+3Qa7g25OvAM1QTpMwmMWL9sY2hxVUGIKVrnj8c4EKuGJjVDXrze5g9O/LfZr5VSjGu5KsN0eYI3mcePF7XM0azMtTNQYVRmeWxYW+XvK5MaoLEkrFG8C5+JccIlN588jowVIPqP321S/EyFiAmrRdAWkqrc9KH+/eINCFqjut2YPkCaTM9mnJAAqWgggUWkrOKT/ByS6IAQwyEBNFbY0TWyxKt6vZL1EW/6HgZCsxeYycNhnPr2qJNZZMNzmdMRp2GRLcfBH8KFw1rAyua0VJoTLHb23ZAsEY74BrEEiK9e/oOjXkHzQjlmrfQ9rSN2eQpRrn0W8I229WmBO2suG+AQ3aY8kDtBMkjmJno7txUh1K5D6tJTO7MQp343A2AhyJkhYA7NPnDA7MB8wBwYFKw4DAhoEFPO82HDlCzlshWlnMoQPStm62TMEBBQsPmvwbZ5OlwC9+NDF1AC+t67WTgICB9A=",
                pfxPassword: "password",
                rentalDurationSeconds: 2249,
                rentalAndLeaseKeyType: "PersistentUnlimited",
            },
            openRestrictionEnabled: true,
        },
        {
            name: "playReady",
            playreadyConfigurationLicenses: [{
                allowTestDevices: true,
                beginDate: "2017-10-16T18:22:53Z",
                playRight: {
                    scmsRestriction: 2,
                    digitalVideoOnlyContentRestriction: false,
                    imageConstraintForAnalogComponentVideoRestriction: false,
                    imageConstraintForAnalogComputerMonitorRestriction: false,
                    allowPassingVideoContentToUnknownOutput: "NotAllowed",
                    uncompressedDigitalVideoOpl: 100,
                    uncompressedDigitalAudioOpl: 100,
                    analogVideoOpl: 150,
                    compressedDigitalAudioOpl: 150,
                },
                licenseType: "Persistent",
                contentType: "UltraVioletDownload",
                contentKeyLocationFromHeaderEnabled: true,
            }],
            openRestrictionEnabled: true,
        },
        {
            name: "clearKey",
            clearKeyConfigurationEnabled: true,
            tokenRestriction: {
                issuer: "urn:issuer",
                audience: "urn:audience",
                tokenType: "Swt",
                primarySymmetricTokenKey: "AAAAAAAAAAAAAAAAAAAAAA==",
            },
        },
        {
            name: "widevine",
            widevineConfigurationTemplate: JSON.stringify({
                allowed_track_types: "SD_HD",
                content_key_specs: [{
                    track_type: "SD",
                    security_level: 1,
                    required_output_protection: {
                        hdcp: "HDCP_V2",
                    },
                }],
                policy_overrides: {
                    can_play: true,
                    can_persist: true,
                    can_renew: false,
                },
            }),
            openRestrictionEnabled: true,
        },
    ],
});
resources:
  exampleResourceGroup:
    type: azure:core:ResourceGroup
    properties:
      location: West Europe
  exampleAccount:
    type: azure:storage:Account
    properties:
      resourceGroupName: ${exampleResourceGroup.name}
      location: ${exampleResourceGroup.location}
      accountTier: Standard
      accountReplicationType: GRS
  exampleServiceAccount:
    type: azure:media:ServiceAccount
    properties:
      location: ${exampleResourceGroup.location}
      resourceGroupName: ${exampleResourceGroup.name}
      storageAccounts:
        - id: ${exampleAccount.id}
          isPrimary: true
  exampleContentKeyPolicy:
    type: azure:media:ContentKeyPolicy
    properties:
      resourceGroupName: ${exampleResourceGroup.name}
      mediaServicesAccountName: ${exampleServiceAccount.name}
      policyOptions:
        - name: fairPlay
          fairplayConfiguration:
            ask: bb566284cc124a21c435a92cd3c108c4
            pfx: MIIG7gIBAzCCBqoGCSqGSIb3DQEHAaCCBpsEggaXMIIGkzCCA7wGCSqGSIb3DQEHAaCCA60EggOpMIIDpTCCA6EGCyqGSIb3DQEMCgECoIICtjCCArIwHAYKKoZIhvcNAQwBAzAOBAiV65vFfxLDVgICB9AEggKQx2dxWefICYodVhRLSQVMJRYy5QkM1VySPAXGP744JHrb+s0Y8i/6a+a5itZGlXw3kvxyflHtSsuuBCaYJ1WOCp9jspixJEliFHXTcel96AgZlT5tB7vC6pdZnz8rb+lyxFs99x2CW52EsadoDlRsYrmkmKdnB0cx2JHJbLeXuKV/fjuRJSqCFcDa6Nre8AlBX0zKGIYGLJ1Cfpora4kNTXxu0AwEowzGmoCxqrpKbO1QDi1hZ1qHrtZ1ienAKfiTXaGH4AMQzyut0AaymxalrRbXibJYuefLRvXqx0oLZKVLAX8fR1gnac6Mrr7GkdHaKCsk4eOi98acR7bjiyRRVYYS4B6Y0tCeRJNe6zeYVmLdtatuOlOEVDT6AKrJJMFMyITVS+2D771ge6m37FbJ36K3/eT/HRq1YDsxfD/BY+X7eMIwQrVnD5nK7avXfbIni57n5oWLkE9Vco8uBlMdrx4xHt9vpe42Pz2Yh2O4WtvxcgxrAknvPpV1ZsAJCfvm9TTcg8qZpjyePn3B9TvFVSXMJHn/rzu6OJAgFgVFAe1tPGLh1XBxAvwpB8EqcycIIUUFUBy4HgYCicjI2jp6s8Kk293Uc/TA2623LrWgP/Xm5hVB7lP1k6W9LDivOlAA96D0Cbk08Yv6arkCYj7ONFO8VZbO0zKAAOLHMw/ZQRIutGLrDlqgTDeRXRuReX7TNjDBxp2rzJBY0uU5g9BMFxQrbQwEx9HsnO4dVFG4KLbHmYWhlwS2V2uZtY6D6elOXY3SX50RwhC4+0trUMi/ODtOxAc+lMQk2FNDcNeKIX5wHwFRS+sFBu5Um4Jfj6Ua4w1izmu2KiPfDd3vJsm5Dgcci3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Y0TWyxKt6vZL1EW/6HgZCsxeYycNhnPr2qJNZZMNzmdMRp2GRLcfBH8KFw1rAyua0VJoTLHb23ZAsEY74BrEEiK9e/oOjXkHzQjlmrfQ9rSN2eQpRrn0W8I229WmBO2suG+AQ3aY8kDtBMkjmJno7txUh1K5D6tJTO7MQp343A2AhyJkhYA7NPnDA7MB8wBwYFKw4DAhoEFPO82HDlCzlshWlnMoQPStm62TMEBBQsPmvwbZ5OlwC9+NDF1AC+t67WTgICB9A=
            pfxPassword: password
            rentalDurationSeconds: 2249
            rentalAndLeaseKeyType: PersistentUnlimited
          openRestrictionEnabled: true
        - name: playReady
          playreadyConfigurationLicenses:
            - allowTestDevices: true
              beginDate: 2017-10-16T18:22:53Z
              playRight:
                scmsRestriction: 2
                digitalVideoOnlyContentRestriction: false
                imageConstraintForAnalogComponentVideoRestriction: false
                imageConstraintForAnalogComputerMonitorRestriction: false
                allowPassingVideoContentToUnknownOutput: NotAllowed
                uncompressedDigitalVideoOpl: 100
                uncompressedDigitalAudioOpl: 100
                analogVideoOpl: 150
                compressedDigitalAudioOpl: 150
              licenseType: Persistent
              contentType: UltraVioletDownload
              contentKeyLocationFromHeaderEnabled: true
          openRestrictionEnabled: true
        - name: clearKey
          clearKeyConfigurationEnabled: true
          tokenRestriction:
            issuer: urn:issuer
            audience: urn:audience
            tokenType: Swt
            primarySymmetricTokenKey: AAAAAAAAAAAAAAAAAAAAAA==
        - name: widevine
          widevineConfigurationTemplate:
            Fn::ToJSON:
              allowed_track_types: SD_HD
              content_key_specs:
                - track_type: SD
                  security_level: 1
                  required_output_protection:
                    hdcp: HDCP_V2
              policy_overrides:
                can_play: true
                can_persist: true
                can_renew: false
          openRestrictionEnabled: true

Create ContentKeyPolicy Resource

new ContentKeyPolicy(name: string, args: ContentKeyPolicyArgs, opts?: CustomResourceOptions);
@overload
def ContentKeyPolicy(resource_name: str,
                     opts: Optional[ResourceOptions] = None,
                     description: Optional[str] = None,
                     media_services_account_name: Optional[str] = None,
                     name: Optional[str] = None,
                     policy_options: Optional[Sequence[ContentKeyPolicyPolicyOptionArgs]] = None,
                     resource_group_name: Optional[str] = None)
@overload
def ContentKeyPolicy(resource_name: str,
                     args: ContentKeyPolicyArgs,
                     opts: Optional[ResourceOptions] = None)
func NewContentKeyPolicy(ctx *Context, name string, args ContentKeyPolicyArgs, opts ...ResourceOption) (*ContentKeyPolicy, error)
public ContentKeyPolicy(string name, ContentKeyPolicyArgs args, CustomResourceOptions? opts = null)
public ContentKeyPolicy(String name, ContentKeyPolicyArgs args)
public ContentKeyPolicy(String name, ContentKeyPolicyArgs args, CustomResourceOptions options)
type: azure:media:ContentKeyPolicy
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args ContentKeyPolicyArgs
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 ContentKeyPolicyArgs
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 ContentKeyPolicyArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args ContentKeyPolicyArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args ContentKeyPolicyArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

ContentKeyPolicy 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 ContentKeyPolicy resource accepts the following input properties:

MediaServicesAccountName string

The Media Services account name. Changing this forces a new Content Key Policy to be created.

PolicyOptions List<ContentKeyPolicyPolicyOptionArgs>

One or more policy_option blocks as defined below.

ResourceGroupName string

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

Description string

A description for the Policy.

Name string

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

MediaServicesAccountName string

The Media Services account name. Changing this forces a new Content Key Policy to be created.

PolicyOptions []ContentKeyPolicyPolicyOptionArgs

One or more policy_option blocks as defined below.

ResourceGroupName string

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

Description string

A description for the Policy.

Name string

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

mediaServicesAccountName String

The Media Services account name. Changing this forces a new Content Key Policy to be created.

policyOptions List<ContentKeyPolicyPolicyOptionArgs>

One or more policy_option blocks as defined below.

resourceGroupName String

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

description String

A description for the Policy.

name String

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

mediaServicesAccountName string

The Media Services account name. Changing this forces a new Content Key Policy to be created.

policyOptions ContentKeyPolicyPolicyOptionArgs[]

One or more policy_option blocks as defined below.

resourceGroupName string

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

description string

A description for the Policy.

name string

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

media_services_account_name str

The Media Services account name. Changing this forces a new Content Key Policy to be created.

policy_options Sequence[ContentKeyPolicyPolicyOptionArgs]

One or more policy_option blocks as defined below.

resource_group_name str

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

description str

A description for the Policy.

name str

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

mediaServicesAccountName String

The Media Services account name. Changing this forces a new Content Key Policy to be created.

policyOptions List<Property Map>

One or more policy_option blocks as defined below.

resourceGroupName String

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

description String

A description for the Policy.

name String

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

Outputs

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

Id string

The provider-assigned unique ID for this managed resource.

Id string

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

id string

The provider-assigned unique ID for this managed resource.

id str

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

Look up Existing ContentKeyPolicy Resource

Get an existing ContentKeyPolicy resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: ContentKeyPolicyState, opts?: CustomResourceOptions): ContentKeyPolicy
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        description: Optional[str] = None,
        media_services_account_name: Optional[str] = None,
        name: Optional[str] = None,
        policy_options: Optional[Sequence[ContentKeyPolicyPolicyOptionArgs]] = None,
        resource_group_name: Optional[str] = None) -> ContentKeyPolicy
func GetContentKeyPolicy(ctx *Context, name string, id IDInput, state *ContentKeyPolicyState, opts ...ResourceOption) (*ContentKeyPolicy, error)
public static ContentKeyPolicy Get(string name, Input<string> id, ContentKeyPolicyState? state, CustomResourceOptions? opts = null)
public static ContentKeyPolicy get(String name, Output<String> id, ContentKeyPolicyState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
Description string

A description for the Policy.

MediaServicesAccountName string

The Media Services account name. Changing this forces a new Content Key Policy to be created.

Name string

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

PolicyOptions List<ContentKeyPolicyPolicyOptionArgs>

One or more policy_option blocks as defined below.

ResourceGroupName string

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

Description string

A description for the Policy.

MediaServicesAccountName string

The Media Services account name. Changing this forces a new Content Key Policy to be created.

Name string

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

PolicyOptions []ContentKeyPolicyPolicyOptionArgs

One or more policy_option blocks as defined below.

ResourceGroupName string

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

description String

A description for the Policy.

mediaServicesAccountName String

The Media Services account name. Changing this forces a new Content Key Policy to be created.

name String

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

policyOptions List<ContentKeyPolicyPolicyOptionArgs>

One or more policy_option blocks as defined below.

resourceGroupName String

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

description string

A description for the Policy.

mediaServicesAccountName string

The Media Services account name. Changing this forces a new Content Key Policy to be created.

name string

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

policyOptions ContentKeyPolicyPolicyOptionArgs[]

One or more policy_option blocks as defined below.

resourceGroupName string

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

description str

A description for the Policy.

media_services_account_name str

The Media Services account name. Changing this forces a new Content Key Policy to be created.

name str

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

policy_options Sequence[ContentKeyPolicyPolicyOptionArgs]

One or more policy_option blocks as defined below.

resource_group_name str

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

description String

A description for the Policy.

mediaServicesAccountName String

The Media Services account name. Changing this forces a new Content Key Policy to be created.

name String

The name which should be used for this Content Key Policy. Changing this forces a new Content Key Policy to be created.

policyOptions List<Property Map>

One or more policy_option blocks as defined below.

resourceGroupName String

The name of the Resource Group where the Content Key Policy should exist. Changing this forces a new Content Key Policy to be created.

Supporting Types

ContentKeyPolicyPolicyOption

Name string

The name which should be used for this Policy Option.

ClearKeyConfigurationEnabled bool

Enable a configuration for non-DRM keys.

FairplayConfiguration ContentKeyPolicyPolicyOptionFairplayConfiguration

A fairplay_configuration block as defined above. Check license requirements here https://docs.microsoft.com/azure/media-services/latest/fairplay-license-overview.

OpenRestrictionEnabled bool

Enable an open restriction. License or key will be delivered on every request.

PlayreadyConfigurationLicenses List<ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicense>

One or more playready_configuration_license blocks as defined above.

TokenRestriction ContentKeyPolicyPolicyOptionTokenRestriction

A token_restriction block as defined below.

WidevineConfigurationTemplate string

The Widevine template.

Name string

The name which should be used for this Policy Option.

ClearKeyConfigurationEnabled bool

Enable a configuration for non-DRM keys.

FairplayConfiguration ContentKeyPolicyPolicyOptionFairplayConfiguration

A fairplay_configuration block as defined above. Check license requirements here https://docs.microsoft.com/azure/media-services/latest/fairplay-license-overview.

OpenRestrictionEnabled bool

Enable an open restriction. License or key will be delivered on every request.

PlayreadyConfigurationLicenses []ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicense

One or more playready_configuration_license blocks as defined above.

TokenRestriction ContentKeyPolicyPolicyOptionTokenRestriction

A token_restriction block as defined below.

WidevineConfigurationTemplate string

The Widevine template.

name String

The name which should be used for this Policy Option.

clearKeyConfigurationEnabled Boolean

Enable a configuration for non-DRM keys.

fairplayConfiguration ContentKeyPolicyPolicyOptionFairplayConfiguration

A fairplay_configuration block as defined above. Check license requirements here https://docs.microsoft.com/azure/media-services/latest/fairplay-license-overview.

openRestrictionEnabled Boolean

Enable an open restriction. License or key will be delivered on every request.

playreadyConfigurationLicenses List<ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicense>

One or more playready_configuration_license blocks as defined above.

tokenRestriction ContentKeyPolicyPolicyOptionTokenRestriction

A token_restriction block as defined below.

widevineConfigurationTemplate String

The Widevine template.

name string

The name which should be used for this Policy Option.

clearKeyConfigurationEnabled boolean

Enable a configuration for non-DRM keys.

fairplayConfiguration ContentKeyPolicyPolicyOptionFairplayConfiguration

A fairplay_configuration block as defined above. Check license requirements here https://docs.microsoft.com/azure/media-services/latest/fairplay-license-overview.

openRestrictionEnabled boolean

Enable an open restriction. License or key will be delivered on every request.

playreadyConfigurationLicenses ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicense[]

One or more playready_configuration_license blocks as defined above.

tokenRestriction ContentKeyPolicyPolicyOptionTokenRestriction

A token_restriction block as defined below.

widevineConfigurationTemplate string

The Widevine template.

name str

The name which should be used for this Policy Option.

clear_key_configuration_enabled bool

Enable a configuration for non-DRM keys.

fairplay_configuration ContentKeyPolicyPolicyOptionFairplayConfiguration

A fairplay_configuration block as defined above. Check license requirements here https://docs.microsoft.com/azure/media-services/latest/fairplay-license-overview.

open_restriction_enabled bool

Enable an open restriction. License or key will be delivered on every request.

playready_configuration_licenses Sequence[ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicense]

One or more playready_configuration_license blocks as defined above.

token_restriction ContentKeyPolicyPolicyOptionTokenRestriction

A token_restriction block as defined below.

widevine_configuration_template str

The Widevine template.

name String

The name which should be used for this Policy Option.

clearKeyConfigurationEnabled Boolean

Enable a configuration for non-DRM keys.

fairplayConfiguration Property Map

A fairplay_configuration block as defined above. Check license requirements here https://docs.microsoft.com/azure/media-services/latest/fairplay-license-overview.

openRestrictionEnabled Boolean

Enable an open restriction. License or key will be delivered on every request.

playreadyConfigurationLicenses List<Property Map>

One or more playready_configuration_license blocks as defined above.

tokenRestriction Property Map

A token_restriction block as defined below.

widevineConfigurationTemplate String

The Widevine template.

ContentKeyPolicyPolicyOptionFairplayConfiguration

Ask string

The key that must be used as FairPlay Application Secret key.

OfflineRentalConfiguration ContentKeyPolicyPolicyOptionFairplayConfigurationOfflineRentalConfiguration

A offline_rental_configuration block as defined below.

Pfx string

The Base64 representation of FairPlay certificate in PKCS 12 (pfx) format (including private key).

PfxPassword string

The password encrypting FairPlay certificate in PKCS 12 (pfx) format.

RentalAndLeaseKeyType string

The rental and lease key type. Supported values are DualExpiry, PersistentLimited, PersistentUnlimited or Undefined.

RentalDurationSeconds int

The rental duration. Must be greater than 0.

Ask string

The key that must be used as FairPlay Application Secret key.

OfflineRentalConfiguration ContentKeyPolicyPolicyOptionFairplayConfigurationOfflineRentalConfiguration

A offline_rental_configuration block as defined below.

Pfx string

The Base64 representation of FairPlay certificate in PKCS 12 (pfx) format (including private key).

PfxPassword string

The password encrypting FairPlay certificate in PKCS 12 (pfx) format.

RentalAndLeaseKeyType string

The rental and lease key type. Supported values are DualExpiry, PersistentLimited, PersistentUnlimited or Undefined.

RentalDurationSeconds int

The rental duration. Must be greater than 0.

ask String

The key that must be used as FairPlay Application Secret key.

offlineRentalConfiguration ContentKeyPolicyPolicyOptionFairplayConfigurationOfflineRentalConfiguration

A offline_rental_configuration block as defined below.

pfx String

The Base64 representation of FairPlay certificate in PKCS 12 (pfx) format (including private key).

pfxPassword String

The password encrypting FairPlay certificate in PKCS 12 (pfx) format.

rentalAndLeaseKeyType String

The rental and lease key type. Supported values are DualExpiry, PersistentLimited, PersistentUnlimited or Undefined.

rentalDurationSeconds Integer

The rental duration. Must be greater than 0.

ask string

The key that must be used as FairPlay Application Secret key.

offlineRentalConfiguration ContentKeyPolicyPolicyOptionFairplayConfigurationOfflineRentalConfiguration

A offline_rental_configuration block as defined below.

pfx string

The Base64 representation of FairPlay certificate in PKCS 12 (pfx) format (including private key).

pfxPassword string

The password encrypting FairPlay certificate in PKCS 12 (pfx) format.

rentalAndLeaseKeyType string

The rental and lease key type. Supported values are DualExpiry, PersistentLimited, PersistentUnlimited or Undefined.

rentalDurationSeconds number

The rental duration. Must be greater than 0.

ask str

The key that must be used as FairPlay Application Secret key.

offline_rental_configuration ContentKeyPolicyPolicyOptionFairplayConfigurationOfflineRentalConfiguration

A offline_rental_configuration block as defined below.

pfx str

The Base64 representation of FairPlay certificate in PKCS 12 (pfx) format (including private key).

pfx_password str

The password encrypting FairPlay certificate in PKCS 12 (pfx) format.

rental_and_lease_key_type str

The rental and lease key type. Supported values are DualExpiry, PersistentLimited, PersistentUnlimited or Undefined.

rental_duration_seconds int

The rental duration. Must be greater than 0.

ask String

The key that must be used as FairPlay Application Secret key.

offlineRentalConfiguration Property Map

A offline_rental_configuration block as defined below.

pfx String

The Base64 representation of FairPlay certificate in PKCS 12 (pfx) format (including private key).

pfxPassword String

The password encrypting FairPlay certificate in PKCS 12 (pfx) format.

rentalAndLeaseKeyType String

The rental and lease key type. Supported values are DualExpiry, PersistentLimited, PersistentUnlimited or Undefined.

rentalDurationSeconds Number

The rental duration. Must be greater than 0.

ContentKeyPolicyPolicyOptionFairplayConfigurationOfflineRentalConfiguration

PlaybackDurationSeconds int

Playback duration.

StorageDurationSeconds int

Storage duration.

PlaybackDurationSeconds int

Playback duration.

StorageDurationSeconds int

Storage duration.

playbackDurationSeconds Integer

Playback duration.

storageDurationSeconds Integer

Storage duration.

playbackDurationSeconds number

Playback duration.

storageDurationSeconds number

Storage duration.

playback_duration_seconds int

Playback duration.

storage_duration_seconds int

Storage duration.

playbackDurationSeconds Number

Playback duration.

storageDurationSeconds Number

Storage duration.

ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicense

AllowTestDevices bool

A flag indicating whether test devices can use the license.

BeginDate string

The begin date of license.

ContentKeyLocationFromHeaderEnabled bool

Specifies that the content key ID is in the PlayReady header.

ContentKeyLocationFromKeyId string

The content key ID. Specifies that the content key ID is specified in the PlayReady configuration.

ContentType string

The PlayReady content type. Supported values are UltraVioletDownload, UltraVioletStreaming or Unspecified.

ExpirationDate string

The expiration date of license.

GracePeriod string

The grace period of license.

LicenseType string

The license type. Supported values are NonPersistent or Persistent.

PlayRight ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicensePlayRight

A play_right block as defined above.

RelativeBeginDate string

The relative begin date of license.

RelativeExpirationDate string

The relative expiration date of license.

AllowTestDevices bool

A flag indicating whether test devices can use the license.

BeginDate string

The begin date of license.

ContentKeyLocationFromHeaderEnabled bool

Specifies that the content key ID is in the PlayReady header.

ContentKeyLocationFromKeyId string

The content key ID. Specifies that the content key ID is specified in the PlayReady configuration.

ContentType string

The PlayReady content type. Supported values are UltraVioletDownload, UltraVioletStreaming or Unspecified.

ExpirationDate string

The expiration date of license.

GracePeriod string

The grace period of license.

LicenseType string

The license type. Supported values are NonPersistent or Persistent.

PlayRight ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicensePlayRight

A play_right block as defined above.

RelativeBeginDate string

The relative begin date of license.

RelativeExpirationDate string

The relative expiration date of license.

allowTestDevices Boolean

A flag indicating whether test devices can use the license.

beginDate String

The begin date of license.

contentKeyLocationFromHeaderEnabled Boolean

Specifies that the content key ID is in the PlayReady header.

contentKeyLocationFromKeyId String

The content key ID. Specifies that the content key ID is specified in the PlayReady configuration.

contentType String

The PlayReady content type. Supported values are UltraVioletDownload, UltraVioletStreaming or Unspecified.

expirationDate String

The expiration date of license.

gracePeriod String

The grace period of license.

licenseType String

The license type. Supported values are NonPersistent or Persistent.

playRight ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicensePlayRight

A play_right block as defined above.

relativeBeginDate String

The relative begin date of license.

relativeExpirationDate String

The relative expiration date of license.

allowTestDevices boolean

A flag indicating whether test devices can use the license.

beginDate string

The begin date of license.

contentKeyLocationFromHeaderEnabled boolean

Specifies that the content key ID is in the PlayReady header.

contentKeyLocationFromKeyId string

The content key ID. Specifies that the content key ID is specified in the PlayReady configuration.

contentType string

The PlayReady content type. Supported values are UltraVioletDownload, UltraVioletStreaming or Unspecified.

expirationDate string

The expiration date of license.

gracePeriod string

The grace period of license.

licenseType string

The license type. Supported values are NonPersistent or Persistent.

playRight ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicensePlayRight

A play_right block as defined above.

relativeBeginDate string

The relative begin date of license.

relativeExpirationDate string

The relative expiration date of license.

allow_test_devices bool

A flag indicating whether test devices can use the license.

begin_date str

The begin date of license.

content_key_location_from_header_enabled bool

Specifies that the content key ID is in the PlayReady header.

content_key_location_from_key_id str

The content key ID. Specifies that the content key ID is specified in the PlayReady configuration.

content_type str

The PlayReady content type. Supported values are UltraVioletDownload, UltraVioletStreaming or Unspecified.

expiration_date str

The expiration date of license.

grace_period str

The grace period of license.

license_type str

The license type. Supported values are NonPersistent or Persistent.

play_right ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicensePlayRight

A play_right block as defined above.

relative_begin_date str

The relative begin date of license.

relative_expiration_date str

The relative expiration date of license.

allowTestDevices Boolean

A flag indicating whether test devices can use the license.

beginDate String

The begin date of license.

contentKeyLocationFromHeaderEnabled Boolean

Specifies that the content key ID is in the PlayReady header.

contentKeyLocationFromKeyId String

The content key ID. Specifies that the content key ID is specified in the PlayReady configuration.

contentType String

The PlayReady content type. Supported values are UltraVioletDownload, UltraVioletStreaming or Unspecified.

expirationDate String

The expiration date of license.

gracePeriod String

The grace period of license.

licenseType String

The license type. Supported values are NonPersistent or Persistent.

playRight Property Map

A play_right block as defined above.

relativeBeginDate String

The relative begin date of license.

relativeExpirationDate String

The relative expiration date of license.

ContentKeyPolicyPolicyOptionPlayreadyConfigurationLicensePlayRight

AgcAndColorStripeRestriction int

Configures Automatic Gain Control (AGC) and Color Stripe in the license. Must be between 0 and 3 inclusive.

AllowPassingVideoContentToUnknownOutput string

Configures Unknown output handling settings of the license. Supported values are Allowed, AllowedWithVideoConstriction or NotAllowed.

AnalogVideoOpl int

Specifies the output protection level for compressed digital audio. Supported values are 100, 150 or 200.

CompressedDigitalAudioOpl int

Specifies the output protection level for compressed digital audio.Supported values are 100, 150 or 200.

DigitalVideoOnlyContentRestriction bool

Enables the Image Constraint For Analog Component Video Restriction in the license.

FirstPlayExpiration string

The amount of time that the license is valid after the license is first used to play content.

ImageConstraintForAnalogComponentVideoRestriction bool

Enables the Image Constraint For Analog Component Video Restriction in the license.

ImageConstraintForAnalogComputerMonitorRestriction bool

Enables the Image Constraint For Analog Component Video Restriction in the license.

ScmsRestriction int

Configures the Serial Copy Management System (SCMS) in the license. Must be between 0 and 3 inclusive.

UncompressedDigitalAudioOpl int

Specifies the output protection level for uncompressed digital audio. Supported values are 100, 150, 250 or 300.

UncompressedDigitalVideoOpl int

Specifies the output protection level for uncompressed digital video. Supported values are 100, 150, 250 or 300.

AgcAndColorStripeRestriction int

Configures Automatic Gain Control (AGC) and Color Stripe in the license. Must be between 0 and 3 inclusive.

AllowPassingVideoContentToUnknownOutput string

Configures Unknown output handling settings of the license. Supported values are Allowed, AllowedWithVideoConstriction or NotAllowed.

AnalogVideoOpl int

Specifies the output protection level for compressed digital audio. Supported values are 100, 150 or 200.

CompressedDigitalAudioOpl int

Specifies the output protection level for compressed digital audio.Supported values are 100, 150 or 200.

DigitalVideoOnlyContentRestriction bool

Enables the Image Constraint For Analog Component Video Restriction in the license.

FirstPlayExpiration string

The amount of time that the license is valid after the license is first used to play content.

ImageConstraintForAnalogComponentVideoRestriction bool

Enables the Image Constraint For Analog Component Video Restriction in the license.

ImageConstraintForAnalogComputerMonitorRestriction bool

Enables the Image Constraint For Analog Component Video Restriction in the license.

ScmsRestriction int

Configures the Serial Copy Management System (SCMS) in the license. Must be between 0 and 3 inclusive.

UncompressedDigitalAudioOpl int

Specifies the output protection level for uncompressed digital audio. Supported values are 100, 150, 250 or 300.

UncompressedDigitalVideoOpl int

Specifies the output protection level for uncompressed digital video. Supported values are 100, 150, 250 or 300.

agcAndColorStripeRestriction Integer

Configures Automatic Gain Control (AGC) and Color Stripe in the license. Must be between 0 and 3 inclusive.

allowPassingVideoContentToUnknownOutput String

Configures Unknown output handling settings of the license. Supported values are Allowed, AllowedWithVideoConstriction or NotAllowed.

analogVideoOpl Integer

Specifies the output protection level for compressed digital audio. Supported values are 100, 150 or 200.

compressedDigitalAudioOpl Integer

Specifies the output protection level for compressed digital audio.Supported values are 100, 150 or 200.

digitalVideoOnlyContentRestriction Boolean

Enables the Image Constraint For Analog Component Video Restriction in the license.

firstPlayExpiration String

The amount of time that the license is valid after the license is first used to play content.

imageConstraintForAnalogComponentVideoRestriction Boolean

Enables the Image Constraint For Analog Component Video Restriction in the license.

imageConstraintForAnalogComputerMonitorRestriction Boolean

Enables the Image Constraint For Analog Component Video Restriction in the license.

scmsRestriction Integer

Configures the Serial Copy Management System (SCMS) in the license. Must be between 0 and 3 inclusive.

uncompressedDigitalAudioOpl Integer

Specifies the output protection level for uncompressed digital audio. Supported values are 100, 150, 250 or 300.

uncompressedDigitalVideoOpl Integer

Specifies the output protection level for uncompressed digital video. Supported values are 100, 150, 250 or 300.

agcAndColorStripeRestriction number

Configures Automatic Gain Control (AGC) and Color Stripe in the license. Must be between 0 and 3 inclusive.

allowPassingVideoContentToUnknownOutput string

Configures Unknown output handling settings of the license. Supported values are Allowed, AllowedWithVideoConstriction or NotAllowed.

analogVideoOpl number

Specifies the output protection level for compressed digital audio. Supported values are 100, 150 or 200.

compressedDigitalAudioOpl number

Specifies the output protection level for compressed digital audio.Supported values are 100, 150 or 200.

digitalVideoOnlyContentRestriction boolean

Enables the Image Constraint For Analog Component Video Restriction in the license.

firstPlayExpiration string

The amount of time that the license is valid after the license is first used to play content.

imageConstraintForAnalogComponentVideoRestriction boolean

Enables the Image Constraint For Analog Component Video Restriction in the license.

imageConstraintForAnalogComputerMonitorRestriction boolean

Enables the Image Constraint For Analog Component Video Restriction in the license.

scmsRestriction number

Configures the Serial Copy Management System (SCMS) in the license. Must be between 0 and 3 inclusive.

uncompressedDigitalAudioOpl number

Specifies the output protection level for uncompressed digital audio. Supported values are 100, 150, 250 or 300.

uncompressedDigitalVideoOpl number

Specifies the output protection level for uncompressed digital video. Supported values are 100, 150, 250 or 300.

agc_and_color_stripe_restriction int

Configures Automatic Gain Control (AGC) and Color Stripe in the license. Must be between 0 and 3 inclusive.

allow_passing_video_content_to_unknown_output str

Configures Unknown output handling settings of the license. Supported values are Allowed, AllowedWithVideoConstriction or NotAllowed.

analog_video_opl int

Specifies the output protection level for compressed digital audio. Supported values are 100, 150 or 200.

compressed_digital_audio_opl int

Specifies the output protection level for compressed digital audio.Supported values are 100, 150 or 200.

digital_video_only_content_restriction bool

Enables the Image Constraint For Analog Component Video Restriction in the license.

first_play_expiration str

The amount of time that the license is valid after the license is first used to play content.

image_constraint_for_analog_component_video_restriction bool

Enables the Image Constraint For Analog Component Video Restriction in the license.

image_constraint_for_analog_computer_monitor_restriction bool

Enables the Image Constraint For Analog Component Video Restriction in the license.

scms_restriction int

Configures the Serial Copy Management System (SCMS) in the license. Must be between 0 and 3 inclusive.

uncompressed_digital_audio_opl int

Specifies the output protection level for uncompressed digital audio. Supported values are 100, 150, 250 or 300.

uncompressed_digital_video_opl int

Specifies the output protection level for uncompressed digital video. Supported values are 100, 150, 250 or 300.

agcAndColorStripeRestriction Number

Configures Automatic Gain Control (AGC) and Color Stripe in the license. Must be between 0 and 3 inclusive.

allowPassingVideoContentToUnknownOutput String

Configures Unknown output handling settings of the license. Supported values are Allowed, AllowedWithVideoConstriction or NotAllowed.

analogVideoOpl Number

Specifies the output protection level for compressed digital audio. Supported values are 100, 150 or 200.

compressedDigitalAudioOpl Number

Specifies the output protection level for compressed digital audio.Supported values are 100, 150 or 200.

digitalVideoOnlyContentRestriction Boolean

Enables the Image Constraint For Analog Component Video Restriction in the license.

firstPlayExpiration String

The amount of time that the license is valid after the license is first used to play content.

imageConstraintForAnalogComponentVideoRestriction Boolean

Enables the Image Constraint For Analog Component Video Restriction in the license.

imageConstraintForAnalogComputerMonitorRestriction Boolean

Enables the Image Constraint For Analog Component Video Restriction in the license.

scmsRestriction Number

Configures the Serial Copy Management System (SCMS) in the license. Must be between 0 and 3 inclusive.

uncompressedDigitalAudioOpl Number

Specifies the output protection level for uncompressed digital audio. Supported values are 100, 150, 250 or 300.

uncompressedDigitalVideoOpl Number

Specifies the output protection level for uncompressed digital video. Supported values are 100, 150, 250 or 300.

ContentKeyPolicyPolicyOptionTokenRestriction

Audience string

The audience for the token.

Issuer string

The token issuer.

OpenIdConnectDiscoveryDocument string

The OpenID connect discovery document.

PrimaryRsaTokenKeyExponent string

The RSA Parameter exponent.

PrimaryRsaTokenKeyModulus string

The RSA Parameter modulus.

PrimarySymmetricTokenKey string

The key value of the key. Specifies a symmetric key for token validation.

PrimaryX509TokenKeyRaw string

The raw data field of a certificate in PKCS 12 format (X509Certificate2 in .NET). Specifies a certificate for token validation.

RequiredClaims List<ContentKeyPolicyPolicyOptionTokenRestrictionRequiredClaim>

One or more required_claim blocks as defined above.

TokenType string

The type of token. Supported values are Jwt or Swt.

Audience string

The audience for the token.

Issuer string

The token issuer.

OpenIdConnectDiscoveryDocument string

The OpenID connect discovery document.

PrimaryRsaTokenKeyExponent string

The RSA Parameter exponent.

PrimaryRsaTokenKeyModulus string

The RSA Parameter modulus.

PrimarySymmetricTokenKey string

The key value of the key. Specifies a symmetric key for token validation.

PrimaryX509TokenKeyRaw string

The raw data field of a certificate in PKCS 12 format (X509Certificate2 in .NET). Specifies a certificate for token validation.

RequiredClaims []ContentKeyPolicyPolicyOptionTokenRestrictionRequiredClaim

One or more required_claim blocks as defined above.

TokenType string

The type of token. Supported values are Jwt or Swt.

audience String

The audience for the token.

issuer String

The token issuer.

openIdConnectDiscoveryDocument String

The OpenID connect discovery document.

primaryRsaTokenKeyExponent String

The RSA Parameter exponent.

primaryRsaTokenKeyModulus String

The RSA Parameter modulus.

primarySymmetricTokenKey String

The key value of the key. Specifies a symmetric key for token validation.

primaryX509TokenKeyRaw String

The raw data field of a certificate in PKCS 12 format (X509Certificate2 in .NET). Specifies a certificate for token validation.

requiredClaims List<ContentKeyPolicyPolicyOptionTokenRestrictionRequiredClaim>

One or more required_claim blocks as defined above.

tokenType String

The type of token. Supported values are Jwt or Swt.

audience string

The audience for the token.

issuer string

The token issuer.

openIdConnectDiscoveryDocument string

The OpenID connect discovery document.

primaryRsaTokenKeyExponent string

The RSA Parameter exponent.

primaryRsaTokenKeyModulus string

The RSA Parameter modulus.

primarySymmetricTokenKey string

The key value of the key. Specifies a symmetric key for token validation.

primaryX509TokenKeyRaw string

The raw data field of a certificate in PKCS 12 format (X509Certificate2 in .NET). Specifies a certificate for token validation.

requiredClaims ContentKeyPolicyPolicyOptionTokenRestrictionRequiredClaim[]

One or more required_claim blocks as defined above.

tokenType string

The type of token. Supported values are Jwt or Swt.

audience str

The audience for the token.

issuer str

The token issuer.

open_id_connect_discovery_document str

The OpenID connect discovery document.

primary_rsa_token_key_exponent str

The RSA Parameter exponent.

primary_rsa_token_key_modulus str

The RSA Parameter modulus.

primary_symmetric_token_key str

The key value of the key. Specifies a symmetric key for token validation.

primary_x509_token_key_raw str

The raw data field of a certificate in PKCS 12 format (X509Certificate2 in .NET). Specifies a certificate for token validation.

required_claims Sequence[ContentKeyPolicyPolicyOptionTokenRestrictionRequiredClaim]

One or more required_claim blocks as defined above.

token_type str

The type of token. Supported values are Jwt or Swt.

audience String

The audience for the token.

issuer String

The token issuer.

openIdConnectDiscoveryDocument String

The OpenID connect discovery document.

primaryRsaTokenKeyExponent String

The RSA Parameter exponent.

primaryRsaTokenKeyModulus String

The RSA Parameter modulus.

primarySymmetricTokenKey String

The key value of the key. Specifies a symmetric key for token validation.

primaryX509TokenKeyRaw String

The raw data field of a certificate in PKCS 12 format (X509Certificate2 in .NET). Specifies a certificate for token validation.

requiredClaims List<Property Map>

One or more required_claim blocks as defined above.

tokenType String

The type of token. Supported values are Jwt or Swt.

ContentKeyPolicyPolicyOptionTokenRestrictionRequiredClaim

Type string

Token claim type.

Value string

Token claim value.

Type string

Token claim type.

Value string

Token claim value.

type String

Token claim type.

value String

Token claim value.

type string

Token claim type.

value string

Token claim value.

type str

Token claim type.

value str

Token claim value.

type String

Token claim type.

value String

Token claim value.

Import

Resource Groups can be imported using the resource id, e.g.

 $ pulumi import azure:media/contentKeyPolicy:ContentKeyPolicy example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.Media/mediaservices/account1/contentkeypolicies/policy1

Package Details

Repository
https://github.com/pulumi/pulumi-azure
License
Apache-2.0
Notes

This Pulumi package is based on the azurerm Terraform Provider.