diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2017-01-04 22:23:07 +0100 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2017-01-04 22:23:07 +0100 |
commit | bdfbd4f162d66c3a6bd7c312a99e0b692e830792 (patch) | |
tree | 30b857f73fe62771a94320e3e78030a1345dc3a8 /server/initializers/constants.js | |
parent | b981a525c37d226b3fa59287a6ce338f54583d0c (diff) | |
download | PeerTube-bdfbd4f162d66c3a6bd7c312a99e0b692e830792.tar.gz PeerTube-bdfbd4f162d66c3a6bd7c312a99e0b692e830792.tar.zst PeerTube-bdfbd4f162d66c3a6bd7c312a99e0b692e830792.zip |
Server: use crypto instead of ursa for pod signature
Diffstat (limited to 'server/initializers/constants.js')
-rw-r--r-- | server/initializers/constants.js | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/server/initializers/constants.js b/server/initializers/constants.js index 6ba8a9da0..a6adb75bf 100644 --- a/server/initializers/constants.js +++ b/server/initializers/constants.js | |||
@@ -118,16 +118,21 @@ const REQUEST_ENDPOINTS = { | |||
118 | VIDEOS: 'videos' | 118 | VIDEOS: 'videos' |
119 | } | 119 | } |
120 | 120 | ||
121 | // --------------------------------------------------------------------------- | ||
122 | |||
123 | const REMOTE_SCHEME = { | 121 | const REMOTE_SCHEME = { |
124 | HTTP: 'https', | 122 | HTTP: 'https', |
125 | WS: 'wss' | 123 | WS: 'wss' |
126 | } | 124 | } |
127 | 125 | ||
126 | // --------------------------------------------------------------------------- | ||
127 | |||
128 | const SIGNATURE_ALGORITHM = 'RSA-SHA256' | ||
129 | const SIGNATURE_ENCODING = 'hex' | ||
130 | |||
128 | // Password encryption | 131 | // Password encryption |
129 | const BCRYPT_SALT_SIZE = 10 | 132 | const BCRYPT_SALT_SIZE = 10 |
130 | 133 | ||
134 | // --------------------------------------------------------------------------- | ||
135 | |||
131 | // Express static paths (router) | 136 | // Express static paths (router) |
132 | const STATIC_PATHS = { | 137 | const STATIC_PATHS = { |
133 | PREVIEWS: '/static/previews/', | 138 | PREVIEWS: '/static/previews/', |
@@ -143,6 +148,8 @@ let STATIC_MAX_AGE = '30d' | |||
143 | const THUMBNAILS_SIZE = '200x110' | 148 | const THUMBNAILS_SIZE = '200x110' |
144 | const PREVIEWS_SIZE = '640x480' | 149 | const PREVIEWS_SIZE = '640x480' |
145 | 150 | ||
151 | // --------------------------------------------------------------------------- | ||
152 | |||
146 | const USER_ROLES = { | 153 | const USER_ROLES = { |
147 | ADMIN: 'admin', | 154 | ADMIN: 'admin', |
148 | USER: 'user' | 155 | USER: 'user' |
@@ -180,6 +187,8 @@ module.exports = { | |||
180 | REQUESTS_LIMIT, | 187 | REQUESTS_LIMIT, |
181 | RETRY_REQUESTS, | 188 | RETRY_REQUESTS, |
182 | SEARCHABLE_COLUMNS, | 189 | SEARCHABLE_COLUMNS, |
190 | SIGNATURE_ALGORITHM, | ||
191 | SIGNATURE_ENCODING, | ||
183 | SORTABLE_COLUMNS, | 192 | SORTABLE_COLUMNS, |
184 | STATIC_MAX_AGE, | 193 | STATIC_MAX_AGE, |
185 | STATIC_PATHS, | 194 | STATIC_PATHS, |