2
1
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2023-12-13 21:00:40 +01:00

Updated the tokens table to have 32 char tokens

no-issue

After discussion with Matt, we decided that 192 bits for the token is a
good number, as it has no padding when base64 encoded and is more secure
than 128 bits, whilst still a managable size.
This commit is contained in:
Fabien O'Carroll 2020-09-17 17:33:43 +01:00
parent 01e62e3d79
commit a862a58b5f
2 changed files with 2 additions and 2 deletions

View file

@ -486,7 +486,7 @@ module.exports = {
},
tokens: {
id: {type: 'string', maxlength: 24, nullable: false, primary: true},
token: {type: 'string', maxlength: 24, nullable: false, index: true},
token: {type: 'string', maxlength: 32, nullable: false, index: true},
data: {type: 'string', maxlength: 2000, nullable: true},
created_at: {type: 'dateTime', nullable: false},
created_by: {type: 'string', maxlength: 24, nullable: false}

View file

@ -32,7 +32,7 @@ const defaultSettings = require('../../../../core/server/data/schema/default-set
*/
describe('DB version integrity', function () {
// Only these variables should need updating
const currentSchemaHash = 'e90889dff39d27934ad7550dcb0e641c';
const currentSchemaHash = '6fb451dbbe6ae6105e92b39c715e9afd';
const currentFixturesHash = '29148c40dfaf4f828c5fca95666f6545';
const currentSettingsHash = 'c8daa2c9632bb75f9d60655de09ae3bd';
const currentRoutesHash = '3d180d52c663d173a6be791ef411ed01';