lint: src/node/db/SecurityManager.js

This commit is contained in:
John McLear 2021-01-21 21:06:52 +00:00 committed by Richard Hansen
parent 5ce255c789
commit 93bc21b5f3

View file

@ -1,3 +1,4 @@
'use strict';
/** /**
* Controls the security of pad access * Controls the security of pad access
*/ */
@ -19,7 +20,7 @@
*/ */
const authorManager = require('./AuthorManager'); const authorManager = require('./AuthorManager');
const hooks = require('ep_etherpad-lite/static/js/pluginfw/hooks.js'); const hooks = require('../../static/js/pluginfw/hooks.js');
const padManager = require('./PadManager'); const padManager = require('./PadManager');
const sessionManager = require('./SessionManager'); const sessionManager = require('./SessionManager');
const settings = require('../utils/Settings'); const settings = require('../utils/Settings');
@ -47,7 +48,7 @@ const DENY = Object.freeze({accessStatus: 'deny'});
* WARNING: Tokens and session IDs MUST be kept secret, otherwise users will be able to impersonate * WARNING: Tokens and session IDs MUST be kept secret, otherwise users will be able to impersonate
* each other (which might allow them to gain privileges). * each other (which might allow them to gain privileges).
*/ */
exports.checkAccess = async function (padID, sessionCookie, token, userSettings) { exports.checkAccess = async (padID, sessionCookie, token, userSettings) => {
if (!padID) { if (!padID) {
authLogger.debug('access denied: missing padID'); authLogger.debug('access denied: missing padID');
return DENY; return DENY;