@pulumi/azure-compliance-policies
Version:
This repository contains a growing set of Compliance Policies to validate your infrastructure using Pulumi's Crossguard Policy-as-Code framework.
272 lines (271 loc) • 14.6 kB
JavaScript
"use strict";
// Copyright 2016-2024, Pulumi Corporation.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
// ------------------------------- WARNING -------------------------------------
// This file was programmatically generated. Do not edit unless you know what
// you're doing.
// ------------------------------- WARNING -------------------------------------
Object.defineProperty(exports, "__esModule", { value: true });
exports.Instance = exports.DataFlowProfile = exports.DataFlowEndpoint = exports.DataFlow = exports.BrokerListener = exports.BrokerAuthorization = exports.BrokerAuthentication = exports.Broker = void 0;
const policy_1 = require("@pulumi/policy");
const compliance_policy_manager_1 = require("@pulumi/compliance-policy-manager");
const v20240701preview_1 = require("@pulumi/azure-native/iotoperations/v20240701preview");
const v20240701preview_2 = require("@pulumi/azure-native/iotoperations/v20240701preview");
const v20240701preview_3 = require("@pulumi/azure-native/iotoperations/v20240701preview");
const v20240701preview_4 = require("@pulumi/azure-native/iotoperations/v20240701preview");
const v20240701preview_5 = require("@pulumi/azure-native/iotoperations/v20240701preview");
const v20240701preview_6 = require("@pulumi/azure-native/iotoperations/v20240701preview");
const v20240701preview_7 = require("@pulumi/azure-native/iotoperations/v20240701preview");
const v20240701preview_8 = require("@pulumi/azure-native/iotoperations/v20240701preview");
var Broker;
(function (Broker) {
/**
* Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.Broker).
*
* @severity medium
* @frameworks none
* @topics api, preview, unstable
* @link https://learn.microsoft.com/en-us/rest/api/azure/
*/
Broker.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({
resourceValidationPolicy: {
name: "azurenative-iotoperations-v20240701preview-broker-disallow-preview-resource",
description: "Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.Broker).",
configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema,
enforcementLevel: "advisory",
validateResource: (0, policy_1.validateResourceOfType)(v20240701preview_1.Broker, (_, args, reportViolation) => {
if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) {
return;
}
reportViolation("Azure Broker shouldn't use an unstable API (iotoperations.v20240701preview.Broker). A compatible replacement can be found at 'iotoperations.Broker'.");
}),
},
vendors: ["azure"],
services: ["iotoperations"],
severity: "medium",
topics: ["api", "unstable", "preview"],
});
})(Broker || (Broker = {}));
exports.Broker = Broker;
var BrokerAuthentication;
(function (BrokerAuthentication) {
/**
* Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.BrokerAuthentication).
*
* @severity medium
* @frameworks none
* @topics api, preview, unstable
* @link https://learn.microsoft.com/en-us/rest/api/azure/
*/
BrokerAuthentication.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({
resourceValidationPolicy: {
name: "azurenative-iotoperations-v20240701preview-brokerauthentication-disallow-preview-resource",
description: "Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.BrokerAuthentication).",
configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema,
enforcementLevel: "advisory",
validateResource: (0, policy_1.validateResourceOfType)(v20240701preview_2.BrokerAuthentication, (_, args, reportViolation) => {
if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) {
return;
}
reportViolation("Azure BrokerAuthentication shouldn't use an unstable API (iotoperations.v20240701preview.BrokerAuthentication). A compatible replacement can be found at 'iotoperations.BrokerAuthentication'.");
}),
},
vendors: ["azure"],
services: ["iotoperations"],
severity: "medium",
topics: ["api", "unstable", "preview"],
});
})(BrokerAuthentication || (BrokerAuthentication = {}));
exports.BrokerAuthentication = BrokerAuthentication;
var BrokerAuthorization;
(function (BrokerAuthorization) {
/**
* Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.BrokerAuthorization).
*
* @severity medium
* @frameworks none
* @topics api, preview, unstable
* @link https://learn.microsoft.com/en-us/rest/api/azure/
*/
BrokerAuthorization.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({
resourceValidationPolicy: {
name: "azurenative-iotoperations-v20240701preview-brokerauthorization-disallow-preview-resource",
description: "Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.BrokerAuthorization).",
configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema,
enforcementLevel: "advisory",
validateResource: (0, policy_1.validateResourceOfType)(v20240701preview_3.BrokerAuthorization, (_, args, reportViolation) => {
if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) {
return;
}
reportViolation("Azure BrokerAuthorization shouldn't use an unstable API (iotoperations.v20240701preview.BrokerAuthorization). A compatible replacement can be found at 'iotoperations.BrokerAuthorization'.");
}),
},
vendors: ["azure"],
services: ["iotoperations"],
severity: "medium",
topics: ["api", "unstable", "preview"],
});
})(BrokerAuthorization || (BrokerAuthorization = {}));
exports.BrokerAuthorization = BrokerAuthorization;
var BrokerListener;
(function (BrokerListener) {
/**
* Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.BrokerListener).
*
* @severity medium
* @frameworks none
* @topics api, preview, unstable
* @link https://learn.microsoft.com/en-us/rest/api/azure/
*/
BrokerListener.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({
resourceValidationPolicy: {
name: "azurenative-iotoperations-v20240701preview-brokerlistener-disallow-preview-resource",
description: "Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.BrokerListener).",
configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema,
enforcementLevel: "advisory",
validateResource: (0, policy_1.validateResourceOfType)(v20240701preview_4.BrokerListener, (_, args, reportViolation) => {
if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) {
return;
}
reportViolation("Azure BrokerListener shouldn't use an unstable API (iotoperations.v20240701preview.BrokerListener). A compatible replacement can be found at 'iotoperations.BrokerListener'.");
}),
},
vendors: ["azure"],
services: ["iotoperations"],
severity: "medium",
topics: ["api", "unstable", "preview"],
});
})(BrokerListener || (BrokerListener = {}));
exports.BrokerListener = BrokerListener;
var DataFlow;
(function (DataFlow) {
/**
* Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.DataFlow).
*
* @severity medium
* @frameworks none
* @topics api, preview, unstable
* @link https://learn.microsoft.com/en-us/rest/api/azure/
*/
DataFlow.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({
resourceValidationPolicy: {
name: "azurenative-iotoperations-v20240701preview-dataflow-disallow-preview-resource",
description: "Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.DataFlow).",
configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema,
enforcementLevel: "advisory",
validateResource: (0, policy_1.validateResourceOfType)(v20240701preview_5.DataFlow, (_, args, reportViolation) => {
if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) {
return;
}
reportViolation("Azure DataFlow shouldn't use an unstable API (iotoperations.v20240701preview.DataFlow). A compatible replacement can be found at 'iotoperations.DataFlow'.");
}),
},
vendors: ["azure"],
services: ["iotoperations"],
severity: "medium",
topics: ["api", "unstable", "preview"],
});
})(DataFlow || (DataFlow = {}));
exports.DataFlow = DataFlow;
var DataFlowEndpoint;
(function (DataFlowEndpoint) {
/**
* Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.DataFlowEndpoint).
*
* @severity medium
* @frameworks none
* @topics api, preview, unstable
* @link https://learn.microsoft.com/en-us/rest/api/azure/
*/
DataFlowEndpoint.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({
resourceValidationPolicy: {
name: "azurenative-iotoperations-v20240701preview-dataflowendpoint-disallow-preview-resource",
description: "Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.DataFlowEndpoint).",
configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema,
enforcementLevel: "advisory",
validateResource: (0, policy_1.validateResourceOfType)(v20240701preview_6.DataFlowEndpoint, (_, args, reportViolation) => {
if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) {
return;
}
reportViolation("Azure DataFlowEndpoint shouldn't use an unstable API (iotoperations.v20240701preview.DataFlowEndpoint). A compatible replacement can be found at 'iotoperations.DataFlowEndpoint'.");
}),
},
vendors: ["azure"],
services: ["iotoperations"],
severity: "medium",
topics: ["api", "unstable", "preview"],
});
})(DataFlowEndpoint || (DataFlowEndpoint = {}));
exports.DataFlowEndpoint = DataFlowEndpoint;
var DataFlowProfile;
(function (DataFlowProfile) {
/**
* Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.DataFlowProfile).
*
* @severity medium
* @frameworks none
* @topics api, preview, unstable
* @link https://learn.microsoft.com/en-us/rest/api/azure/
*/
DataFlowProfile.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({
resourceValidationPolicy: {
name: "azurenative-iotoperations-v20240701preview-dataflowprofile-disallow-preview-resource",
description: "Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.DataFlowProfile).",
configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema,
enforcementLevel: "advisory",
validateResource: (0, policy_1.validateResourceOfType)(v20240701preview_7.DataFlowProfile, (_, args, reportViolation) => {
if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) {
return;
}
reportViolation("Azure DataFlowProfile shouldn't use an unstable API (iotoperations.v20240701preview.DataFlowProfile). A compatible replacement can be found at 'iotoperations.DataFlowProfile'.");
}),
},
vendors: ["azure"],
services: ["iotoperations"],
severity: "medium",
topics: ["api", "unstable", "preview"],
});
})(DataFlowProfile || (DataFlowProfile = {}));
exports.DataFlowProfile = DataFlowProfile;
var Instance;
(function (Instance) {
/**
* Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.Instance).
*
* @severity medium
* @frameworks none
* @topics api, preview, unstable
* @link https://learn.microsoft.com/en-us/rest/api/azure/
*/
Instance.disallowPreviewResource = compliance_policy_manager_1.policyManager.registerPolicy({
resourceValidationPolicy: {
name: "azurenative-iotoperations-v20240701preview-instance-disallow-preview-resource",
description: "Disallow the use of non-stable (Preview) Azure resouces (iotoperations.v20240701preview.Instance).",
configSchema: compliance_policy_manager_1.policyManager.policyConfigSchema,
enforcementLevel: "advisory",
validateResource: (0, policy_1.validateResourceOfType)(v20240701preview_8.Instance, (_, args, reportViolation) => {
if (!compliance_policy_manager_1.policyManager.shouldEvalPolicy(args)) {
return;
}
reportViolation("Azure Instance shouldn't use an unstable API (iotoperations.v20240701preview.Instance). A compatible replacement can be found at 'iotoperations.Instance'.");
}),
},
vendors: ["azure"],
services: ["iotoperations"],
severity: "medium",
topics: ["api", "unstable", "preview"],
});
})(Instance || (Instance = {}));
exports.Instance = Instance;