TMA-IIS-1.2
Ensure 'Host headers' are on all sites
中レベル 1自動iis
説明
Host headers provide the ability to host multiple websites on the same IP address and port. It is recommended that host headers be configured for all sites. Note: Wildcard host headers are now supported. Every http binding must include a host name (IP:port:host); bindings such as *:80: fail. PowerShell 5.1 with the WebAdministration module; run elevated.
チェック方法
監査方法: シェルコマンド
shell
Import-Module WebAdministration -ErrorAction Stop; $bad = @(Get-WebBinding | Where-Object { $_.protocol -eq 'http' -and ($_.bindingInformation -split ':')[2] -eq '' }); if ($bad.Count -eq 0) { 'compliant' } else { 'noncompliant' }- 期待される出力
compliant
修正方法
修正方法: ガイダンスまたは IaC パッチ
Set-WebBinding -Name '<site>' -BindingInformation '*:80:' -PropertyName HostHeader -Value '<fqdn>'
プロパティ
- オペレーティングシステム
- すべて
- タグ
- iisnetwork
- 参照
- CIS Microsoft IIS 10 Benchmark v1.2.1 - 1.2 Ensure 'Host headers' are on all sites
このホストをチェック
監査が許可されているマシンで実行してください。スキャンは読み取り専用です。
shell
tmaegis scan --target iis