summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCheng-Han, Wu2016-03-15 10:39:45 +0800
committerCheng-Han, Wu2016-03-15 10:39:45 +0800
commitf889ffaa9f2f1263e4bd539934efe97e27ea10c8 (patch)
tree1c948a19895316f433c3d7f71b2a336fe98805f9
parent921b5f46523115de9a2fcaf530148b9607b8f537 (diff)
Supported ssl dhparam
Diffstat (limited to '')
-rw-r--r--README.md1
-rw-r--r--app.js1
-rw-r--r--config.js1
3 files changed, 3 insertions, 0 deletions
diff --git a/README.md b/README.md
index 9d1fa90d..cff1cb62 100644
--- a/README.md
+++ b/README.md
@@ -105,6 +105,7 @@ Server-side config.js settings
| sslkeypath | `./cert/client.key` | ssl key path |
| sslcertpath | `./cert/hackmd_io.crt` | ssl cert path |
| sslcapath | `['./cert/COMODORSAAddTrustCA.crt']` | ssl ca chain |
+| dhparampath | `./cert/dhparam.pem` | ssl dhparam path |
| tmppath | `./tmp/` | temp file path |
| postgresqlstring | `postgresql://user:pass@host:port/hackmd` | PostgreSQL connection string, fallback to this when not set in environment |
| mongodbstring | `mongodb://user:pass@host:port/hackmd` | MongoDB connection string, fallback to this when not set in environment |
diff --git a/app.js b/app.js
index 29162ecb..9ab1e82a 100644
--- a/app.js
+++ b/app.js
@@ -40,6 +40,7 @@ if (config.usessl) {
key: fs.readFileSync(config.sslkeypath, 'utf8'),
cert: fs.readFileSync(config.sslcertpath, 'utf8'),
ca: ca,
+ dhparam: fs.readFileSync(config.dhparampath, 'utf8'),
requestCert: false,
rejectUnauthorized: false
};
diff --git a/config.js b/config.js
index 0d47c8c7..69f44a06 100644
--- a/config.js
+++ b/config.js
@@ -24,6 +24,7 @@ var config = {
sslkeypath: 'change this',
sslcertpath: 'change this',
sslcapath: ['change this'],
+ dhparampath: 'change this',
usessl: usessl,
getserverurl: function() {
var url = domain;