array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'ja', ), 'this' => array ( 0 => 'function.openssl-pkey-export.php', 1 => 'openssl_pkey_export', ), 'up' => array ( 0 => 'ref.openssl.php', 1 => 'OpenSSL 関数', ), 'prev' => array ( 0 => 'function.openssl-pkey-export-to-file.php', 1 => 'openssl_pkey_export_to_file', ), 'next' => array ( 0 => 'function.openssl-pkey-free.php', 1 => 'openssl_pkey_free', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'ja', 'path' => 'reference/openssl/functions/openssl-pkey-export.xml', ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); ?>
(PHP 4 >= 4.2.0, PHP 5, PHP 7, PHP 8)
openssl_pkey_export — エクスポート可能な形式で、キーを文字列に取得する
$key
,&$output
,$passphrase
= null
,$options
= null
openssl_pkey_export() は、
key
を PEM エンコードした文字列として取得し、
output
(リファレンス渡し)に格納します。
注意: この関数を正しく動作させるには、正しい形式の openssl.cnf をインストールしておく必要があります。 詳細な情報は、インストールについてのセクション を参照ください。
key
output
passphrase
オプションで passphrase
を使用してキーを保護することが可能です。
options
options
により openssl 設定ファイルの設定を
追加したり上書きしたりすることで、エクスポート処理の詳細設定が可能です。
options
についての詳細な情報は
openssl_csr_new() を参照ください。
バージョン | 説明 |
---|---|
8.0.0 |
key は、
OpenSSLAsymmetricKey または
OpenSSLCertificate クラスのインスタンスを受け入れるようになりました。
これより前のバージョンでは、
OpenSSL key または
OpenSSL X.509 型のリソースを受け入れていました。
|