PHP8 openssl_x509_export_to_file

2024-03-13 11:24 更新

(PHP 4 >= 4.2.0, PHP 5, PHP 7, PHP 8)

openssl_x509_export_to_file — 導(dǎo)出證書至文件

說明

openssl_x509_export_to_file(OpenSSLCertificate|string $certificate, string $output_filename, bool $no_text = true): bool

openssl_x509_export_to_file() 將 certificate 以 PEM 編碼的格式保存到名為 output_filename 的文件中。

參數(shù) 

x509

參見密鑰/證書參數(shù)以獲取有效值列表。

output_filename

輸出文件的路徑。

no_text

可選參數(shù) notext 影響輸出的冗余度。如果設(shè)為 false,輸出內(nèi)容將包含附加的人類可讀信息。notext 的缺省值為 true。

返回值 

成功時返回 true, 或者在失敗時返回 false。

更新日志 

版本說明
8.0.0certificate 現(xiàn)在接受 OpenSSLCertificate 實(shí)例;之前接受類型 OpenSSL X.509 的 resource。


以上內(nèi)容是否對您有幫助:
在線筆記
App下載
App下載

掃描二維碼

下載編程獅App

公眾號
微信公眾號

編程獅公眾號