- Mastering Node.js(Second Edition)
- Sandro Pasquali Kevin Faaborg
- 156字
- 2021-07-02 19:28:50
Installing a real SSL certificate
In order to move a secure application out of a development environment and into an internet-exposed environment, a real certificate will need to be purchased. The prices of these certificates has been dropping year by year, and it should be easy to find reasonably priced providers of certificates with a high-enough level of security. Some providers even offer free person-use certificates.
Setting up a professional cert simply requires changing the HTTPS options we introduced previously. Different providers will have different processes and filenames. Typically, you will need to download or otherwise receive from your provider a private .key file, your signed domain certificate .crt file, and a bundle describing certificate chains:
let options = {
key: fs.readFileSync("mysite.key"),
cert: fs.readFileSync("mysite.com.crt"),
ca: [ fs.readFileSync("gd_bundle.crt") ]
};
It is important to note that the ca parameter must be sent as an array, even if the bundle of certificates has been concatenated into one file.
- 物聯(lián)網(wǎng)識別技術(shù)
- 智能網(wǎng)聯(lián)汽車V2X與智能網(wǎng)聯(lián)設(shè)施I2X
- Getting Started with WebRTC
- 物聯(lián)網(wǎng)之霧:基于霧計算的智能硬件快速反應(yīng)與安全控制
- 基于性能的保障理論與方法
- 網(wǎng)絡(luò)環(huán)境中基于用戶視角的信息質(zhì)量評價研究
- 5G時代的大數(shù)據(jù)技術(shù)架構(gòu)和關(guān)鍵技術(shù)詳解
- Implementing NetScaler VPX?
- 園區(qū)網(wǎng)絡(luò)架構(gòu)與技術(shù)
- 5G非正交多址接入技術(shù):理論、算法與實現(xiàn)
- 物聯(lián)網(wǎng)與智慧廣電
- Hands-On Reactive Programming in Spring 5
- INSTANT Social Media Marketing with HootSuite
- 物聯(lián)網(wǎng)傳感器技術(shù)與應(yīng)用
- VMware vSphere 5.0虛擬化架構(gòu)實戰(zhàn)指南