9.2. FIPS モードを有効にして Anaconda インストールを実行する
Anaconda インストールの実行時にディスクイメージを作成し、FIPS モードを有効にするには、以下の手順に従います。
前提条件
- Podman がホストマシンにインストールされている。
-
virt-installがホストマシンにインストールされている。 -
bootc-image-builderツールを実行し、コンテナーを--privilegedモードで実行して、イメージをビルドするための root アクセスがある。
手順
01-fips.tomlを作成して FIPS の有効化を設定します。次に例を示します。# Enable FIPS kargs = ["fips=1"]次の手順で Containerfile を作成して、
fips=1カーネル引数を有効にします。FROM registry.redhat.io/rhel9/rhel-bootc:latest # Enable fips=1 kernel argument: https://bootc-dev.github.io/bootc/building/kernel-arguments.html COPY 01-fips.toml /usr/lib/bootc/kargs.d/ # Install and enable the FIPS system-wide cryptographic policy RUN dnf install -y crypto-policies-scripts && update-crypto-policies --no-reload --set FIPSカレントディレクトリーの
Containerfileを使用して、bootc<image>と互換性のあるベースディスクイメージを作成します。$ sudo podman run \ --rm \ -it \ --privileged \ --pull=newer \ --security-opt label=type:unconfined_t \ -v $(pwd)/config.toml:/config.toml:ro \ -v $(pwd)/output:/output \ -v /var/lib/containers/storage:/var/lib/containers/storage \ registry.redhat.io/rhel9/bootc-image-builder:latest \ --local --type iso \ quay.io/<namespace>/<image>:<tag>システムのインストール中に FIPS モードを有効にします。
RHEL Anaconda インストーラーを起動するときに、インストール画面で TAB キーを押して、
fips=1カーネル引数を追加します。インストール後に、システムは FIPS モードで自動的に起動します。
検証
システムにログインした後、FIPS モードが有効になっていることを確認します。
$ cat /proc/sys/crypto/fips_enabled 1 $ update-crypto-policies --show FIPS