77 lines
1.7 KiB
Plaintext
77 lines
1.7 KiB
Plaintext
![]() |
== Why is this an issue?
|
||
|
|
||
|
include::rationale.adoc[]
|
||
|
|
||
|
include::../impact.adoc[]
|
||
|
|
||
|
== How to fix it
|
||
|
|
||
|
include::../common/how-to-fix-it/intro.adoc[]
|
||
|
|
||
|
=== Code examples
|
||
|
|
||
|
==== Noncompliant code example
|
||
|
|
||
|
[source,json,diff-id=1,diff-type=noncompliant]
|
||
|
----
|
||
|
{
|
||
|
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
|
||
|
"contentVersion": "1.0.0.0",
|
||
|
"resources": [
|
||
|
{
|
||
|
"type": "Microsoft.Network/networkSecurityGroups/securityRules",
|
||
|
"apiVersion": "2022-11-01",
|
||
|
"properties": {
|
||
|
"protocol": "*",
|
||
|
"destinationPortRange": "*",
|
||
|
"sourceAddressPrefix": "*",
|
||
|
"access": "Allow",
|
||
|
"direction": "Inbound"
|
||
|
}
|
||
|
}
|
||
|
]
|
||
|
}
|
||
|
----
|
||
|
|
||
|
==== Compliant solution
|
||
|
|
||
|
[source,json,diff-id=1,diff-type=compliant]
|
||
|
----
|
||
|
{
|
||
|
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
|
||
|
"contentVersion": "1.0.0.0",
|
||
|
"resources": [
|
||
|
{
|
||
|
"type": "Microsoft.Network/networkSecurityGroups/securityRules",
|
||
|
"apiVersion": "2022-11-01",
|
||
|
"properties": {
|
||
|
"protocol": "*",
|
||
|
"destinationPortRange": "22",
|
||
|
"sourceAddressPrefix": "10.0.0.0/24",
|
||
|
"access": "Allow",
|
||
|
"direction": "Inbound"
|
||
|
}
|
||
|
}
|
||
|
]
|
||
|
}
|
||
|
----
|
||
|
|
||
|
== Resources
|
||
|
|
||
|
include::../common/resources/docs.adoc[]
|
||
|
|
||
|
include::../common/resources/articles.adoc[]
|
||
|
|
||
|
include::../common/resources/presentations.adoc[]
|
||
|
|
||
|
include::../common/resources/standards.adoc[]
|
||
|
|
||
|
|
||
|
ifdef::env-github,rspecator-view[]
|
||
|
|
||
|
'''
|
||
|
== Implementation Specification
|
||
|
(visible only on this page)
|
||
|
|
||
|
'''
|