今天在安裝 SmbFTPD 時,需要用到 # mkdir ssl # cd ssl # openssl genrsa -out ca.key 1024 # openssl req -new -key ca.key -out ca.csr You are about to be asked to enter information that will be incorporated into your certificate request. What you are about to enter is what is called a Distinguished Name or a DN. There are quite a few fields but you can leave some blank For some fields there will be a default value, If you enter '.', the field will be left blank. ----- Country Name (2 letter code) [AU]:TW State or Province Name (full name) [Some-State]:Taiwan Locality Name (eg, city) []:Taipei Organization Name (eg, company) [Internet Widgits Pty Ltd]:My Company Organizational Unit Name (eg, section) []:Certificate Authority Common Name (eg, YOUR name) []:MyCA Email Address []:alex@alexwang.com Please enter the following 'extra' attributes to be sent with your certificate request A challenge password []:按 Enter 即可 An optional company name []:按 Enter 即可 # openssl x509 -days 365 -signkey ca.key -in ca.csr -req -out ca.crt 我們在第二個 openssl 指令中必須輸入一些基本資訊,最後產生一個有效期限 365 天的憑證。接著,必須產生 Apache 伺服器用的憑證: # openssl genrsa -out server.key 1024 # openssl req -new -key server.key -out server.csr You are about to be asked to enter information that will be incorporated into your certificate request. What you are about to enter is what is called a Distinguished Name or a DN. There are quite a few fields but you can leave some blank For some fields there will be a default value, If you enter '.', the field will be left blank. ----- Country Name (2 letter code) [AU]:TW State or Province Name (full name) [Some-State]:Taiwan Locality Name (eg, city) []:Taipei Organization Name (eg, company) [Internet Widgits Pty Ltd]:My Company Organizational Unit Name (eg, section) []:Web Team Common Name (eg, YOUR name) []:www.alexwang.com Email Address []:alex@alexwang.com Please enter the following 'extra' attributes to be sent with your certificate request A challenge password []:按 Enter 即可 An optional company name []:按 Enter 即可 # openssl x509 -days 365 -CA ca.crt -CAkey ca.key -in server.csr -req -out server.crt 參考來源:https://www.twbsd.org/cht/book/index.php?ch=14 相關網頁:SmbFTPD 使用手冊
創作者介紹
創作者 奇幻世界  賦予你奇妙的感覺 的頭像
daky

奇幻世界 賦予你奇妙的感覺

daky 發表在 痞客邦 留言(0) 人氣( 194 )