diff --git a/imap-core/lib/commands/id.js b/imap-core/lib/commands/id.js index cb5fffd..05528e7 100644 --- a/imap-core/lib/commands/id.js +++ b/imap-core/lib/commands/id.js @@ -55,9 +55,17 @@ module.exports = { this.id ); + let logdata = { + short_message: '[CLIENT ID]', + _mail_action: 'client_id', + _user: this.session && this.session.user && this.session.user.id && this.session.user.id.toString(), + _sess: this.id + }; + Object.keys(clientId) .sort((a, b) => allowedKeys.indexOf(a) - allowedKeys.indexOf(b)) .forEach(key => { + logdata[`_client_id_${key}`] = clientId[key]; this._server.logger.info( { tnx: 'id', @@ -70,6 +78,8 @@ module.exports = { clientId[key] ); }); + + this._server.loggelf(logdata); } // Create response ID serverIdList @@ -93,9 +103,9 @@ module.exports = { attributes: serverIdList.length ? [serverIdList] : { - type: 'atom', - value: 'NIL' - } + type: 'atom', + value: 'NIL' + } }) ); diff --git a/package.json b/package.json index cc455ac..3e23f51 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "wildduck", - "version": "1.23.5", + "version": "1.23.6", "description": "IMAP/POP3 server built with Node.js and MongoDB", "main": "server.js", "scripts": { @@ -16,20 +16,20 @@ "license": "EUPL-1.1+", "devDependencies": { "ajv": "6.12.0", - "apidoc": "0.20.0", + "apidoc": "0.20.1", "browserbox": "0.9.1", "chai": "4.2.0", "eslint": "6.8.0", "eslint-config-nodemailer": "1.2.0", - "eslint-config-prettier": "6.10.0", - "grunt": "1.0.4", + "eslint-config-prettier": "6.10.1", + "grunt": "1.1.0", "grunt-cli": "1.3.2", "grunt-eslint": "22.0.0", "grunt-mocha-test": "0.13.3", "grunt-shell-spawn": "0.4.0", "grunt-wait": "0.3.0", "mailparser": "2.7.7", - "mocha": "7.1.0", + "mocha": "7.1.1", "request": "2.88.2", "supertest": "4.0.2" }, @@ -59,7 +59,7 @@ "mongodb": "3.5.5", "mongodb-extended-json": "1.11.0", "node-forge": "0.9.1", - "nodemailer": "6.4.5", + "nodemailer": "6.4.6", "npmlog": "4.1.2", "openpgp": "4.10.1", "pem": "1.14.4", @@ -68,13 +68,13 @@ "restify": "8.5.1", "restify-logger": "2.0.1", "seq-index": "1.1.0", - "smtp-server": "3.5.0", + "smtp-server": "3.6.0", "speakeasy": "2.0.0", "u2f": "0.1.3", "utf7": "1.0.2", "uuid": "7.0.2", "wild-config": "1.5.0", - "yargs": "15.3.0" + "yargs": "15.3.1" }, "repository": { "type": "git",