aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2015-10-29 23:29:12 +0100
committerChocobozzz <florian.bigard@gmail.com>2015-10-29 23:29:42 +0100
commitd148f3b9b180f43d63de84383938de0c9f51b583 (patch)
treee6f613706acf898bd071b6bd374c85a8f2941dc7 /src
parent241abd6977790bc31ba66ede2fbe23d4b94d117b (diff)
downloadPeerTube-d148f3b9b180f43d63de84383938de0c9f51b583.tar.gz
PeerTube-d148f3b9b180f43d63de84383938de0c9f51b583.tar.zst
PeerTube-d148f3b9b180f43d63de84383938de0c9f51b583.zip
Replace PeopleTube/PeTube by the new name PeerTube
Diffstat (limited to 'src')
-rw-r--r--src/database.js2
-rw-r--r--src/pods.js4
-rw-r--r--src/utils.js8
3 files changed, 7 insertions, 7 deletions
diff --git a/src/database.js b/src/database.js
index 6fbd5dbc8..020bfd961 100644
--- a/src/database.js
+++ b/src/database.js
@@ -6,7 +6,7 @@
6 6
7 var logger = require('./logger') 7 var logger = require('./logger')
8 8
9 var dbname = 'petube' + config.get('database.suffix') 9 var dbname = 'peertube' + config.get('database.suffix')
10 var host = config.get('database.host') 10 var host = config.get('database.host')
11 var port = config.get('database.port') 11 var port = config.get('database.port')
12 12
diff --git a/src/pods.js b/src/pods.js
index 9d6539685..30d465ee5 100644
--- a/src/pods.js
+++ b/src/pods.js
@@ -53,7 +53,7 @@
53 return callback(err) 53 return callback(err)
54 } 54 }
55 55
56 fs.readFile(utils.certDir + 'petube.pub', 'utf8', function (err, cert) { 56 fs.readFile(utils.certDir + 'peertube.pub', 'utf8', function (err, cert) {
57 if (err) { 57 if (err) {
58 logger.error('Cannot read cert file.', { error: err }) 58 logger.error('Cannot read cert file.', { error: err })
59 return callback(err) 59 return callback(err)
@@ -99,7 +99,7 @@
99 99
100 pods.makeFriends = function (callback) { 100 pods.makeFriends = function (callback) {
101 logger.debug('Read public key...') 101 logger.debug('Read public key...')
102 fs.readFile(utils.certDir + 'petube.pub', 'utf8', function (err, cert) { 102 fs.readFile(utils.certDir + 'peertube.pub', 'utf8', function (err, cert) {
103 if (err) { 103 if (err) {
104 logger.error('Cannot read public cert.', { error: err }) 104 logger.error('Cannot read public cert.', { error: err })
105 return callback(err) 105 return callback(err)
diff --git a/src/utils.js b/src/utils.js
index 0b21565dd..82a62c43f 100644
--- a/src/utils.js
+++ b/src/utils.js
@@ -63,7 +63,7 @@
63 63
64 // Signature ? 64 // Signature ?
65 if (all.method === 'POST' && all.data && all.sign === true) { 65 if (all.method === 'POST' && all.data && all.sign === true) {
66 var myKey = ursa.createPrivateKey(fs.readFileSync(utils.certDir + 'petube.key.pem')) 66 var myKey = ursa.createPrivateKey(fs.readFileSync(utils.certDir + 'peertube.key.pem'))
67 signature = myKey.hashAndSign('sha256', url, 'utf8', 'hex') 67 signature = myKey.hashAndSign('sha256', url, 'utf8', 'hex')
68 } 68 }
69 69
@@ -111,7 +111,7 @@
111 } 111 }
112 112
113 utils.certsExist = function (callback) { 113 utils.certsExist = function (callback) {
114 fs.exists(utils.certDir + 'petube.key.pem', function (exists) { 114 fs.exists(utils.certDir + 'peertube.key.pem', function (exists) {
115 return callback(exists) 115 return callback(exists)
116 }) 116 })
117 } 117 }
@@ -125,14 +125,14 @@
125 } 125 }
126 126
127 logger.debug('Gen RSA keys...') 127 logger.debug('Gen RSA keys...')
128 openssl.exec('genrsa', { 'out': utils.certDir + 'petube.key.pem' }, function (err) { 128 openssl.exec('genrsa', { 'out': utils.certDir + 'peertube.key.pem' }, function (err) {
129 if (err) { 129 if (err) {
130 logger.error('Cannot create private key on this pod.', { error: err }) 130 logger.error('Cannot create private key on this pod.', { error: err })
131 return callback(err) 131 return callback(err)
132 } 132 }
133 133
134 logger.debug('Manage public key...') 134 logger.debug('Manage public key...')
135 openssl.exec('rsa', { 'in': utils.certDir + 'petube.key.pem', 'pubout': true, 'out': utils.certDir + 'petube.pub' }, function (err) { 135 openssl.exec('rsa', { 'in': utils.certDir + 'peertube.key.pem', 'pubout': true, 'out': utils.certDir + 'peertube.pub' }, function (err) {
136 if (err) { 136 if (err) {
137 logger.error('Cannot create public key on this pod .', { error: err }) 137 logger.error('Cannot create public key on this pod .', { error: err })
138 return callback(err) 138 return callback(err)