0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

SSL証明書の形式変換:CSRバンドルからPFXファイル

Last updated at Posted at 2025-05-16

SSL証明書をインストールする際、Linux系サーバでは .crt(証明書)や .key(秘密鍵)形式が一般的ですが、Windows/IISや一部クラウドサービス(Azure、AWS ACMなど)では .pfx 形式が求められるケースがあります。

準備するファイル

PFX形式を生成するには、以下の3つのファイルが必要です:

ファイル名 役割
your_domain.crt サーバ証明書(CAから発行されたもの)
your_domain.key 秘密鍵(CSR作成時に生成したもの)
intermediate.crt または ca-bundle.crt 中間CA証明書(CAが提供)

OpenSSLでの変換コマンド

openssl pkcs12 -export \
  -out your_domain.pfx \
  -inkey your_domain.key \
  -in your_domain.crt \
  -certfile intermediate.crt

各オプションの意味

  • -export: PFX形式で出力する
  • -out: 出力先ファイル名(PFXファイル)
  • -inkey: 秘密鍵ファイル
  • -in: サーバ証明書
  • -certfile: 中間CA証明書(バンドル)

変換後の用途例

  • Windowsサーバ(IIS)でのSSL設定
  • Azure App Serviceでのカスタムドメイン証明書設定
  • AWS Certificate Manager(インポート型)での利用
0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?