{
    "properties": {
        "displayName": "Audit Windows VMs on which the remote host connection status does not match the specified one",
        "policyType": "BuiltIn",
        "description": "This initiative deploys the policy requirements and audits Windows virtual machines on which the remote host connection status does not match the specified one. For more information on Guest Configuration policies, please visit https://aka.ms/gcpol",
        "metadata": {
            "version": "1.0.0-deprecated",
            "category": "Guest Configuration",
            "deprecated": true
        },
        "parameters": {
            "host": {
                "type": "string",
                "metadata": {
                    "displayName": "Remote Host Name",
                    "description": "Specifies the Domain Name System (DNS) name or IP address of the remote host machine."
                }
            },
            "port": {
                "type": "string",
                "metadata": {
                    "displayName": "Port",
                    "description": "The TCP port number on the remote host name."
                }
            },
            "shouldConnect": {
                "type": "string",
                "metadata": {
                    "displayName": "Should connect to remote host",
                    "description": "Must be 'True' or 'False'. 'True' indicates that the virtual machine should be able to establish a connection with the remote host specified, so the machine will be non-compliant if it cannot establish a connection. 'False' indicates that the virtual machine should not be able to establish a connection with the remote host specified, so the machine will be non-compliant if it can establish a connection."
                },
                "allowedValues": [
                    "True",
                    "False"
                ],
                "defaultValue": "False"
            }
        },
        "policyDefinitions": [
            {
                "policyDefinitionId": "/providers/Microsoft.Authorization/policyDefinitions/5bb36dda-8a78-4df9-affd-4f05a8612a8a",
                "policyDefinitionReferenceId": "Deploy_WindowsRemoteConnection",
                "parameters": {
                    "host": {
                        "value": "[parameters('host')]"
                    },
                    "port": {
                        "value": "[parameters('port')]"
                    },
                    "shouldConnect": {
                        "value": "[parameters('shouldConnect')]"
                    }
                }
            },
            {
                "policyDefinitionId": "/providers/Microsoft.Authorization/policyDefinitions/02a84be7-c304-421f-9bb7-5d2c26af54ad",
                "policyDefinitionReferenceId": "Audit_WindowsRemoteConnection"
            }
        ]
    },
    "id": "/providers/Microsoft.Authorization/policySetDefinitions/4ddaefff-7c78-4824-9b27-5c344f3cdf90",
    "name": "4ddaefff-7c78-4824-9b27-5c344f3cdf90"
}