Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions lib/api/asps.js
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,7 @@ module.exports = (db, server, userHandler) => {
.default(false)
.description('If true then result contains a mobileconfig formatted file with account config'),
ttl: Joi.number().empty([0, '']).description('TTL in seconds for this password. Every time password is used, TTL is reset to this value'),
protocol: Joi.string().default('API').description('Application identifier for security logs'),
sess: sessSchema,
ip: sessIPSchema
},
Expand Down Expand Up @@ -579,6 +580,7 @@ module.exports = (db, server, userHandler) => {
validationObjs: {
requestBody: {},
queryParams: {
protocol: Joi.string().default('API').description('Application identifier for security logs'),
sess: sessSchema,
ip: sessIPSchema
},
Expand Down
1 change: 1 addition & 0 deletions lib/api/users.js
Original file line number Diff line number Diff line change
Expand Up @@ -1272,6 +1272,7 @@ module.exports = (db, server, userHandler, settingsHandler) => {

suspended: booleanSchema.description('If true then disables authentication'),

protocol: Joi.string().default('API').description('Application identifier for security logs'),
sess: sessSchema,
ip: sessIPSchema
},
Expand Down
4 changes: 4 additions & 0 deletions lib/user-handler.js
Original file line number Diff line number Diff line change
Expand Up @@ -1307,6 +1307,7 @@ class UserHandler {
aname: aspData.description,
temporary: aspData.ttl ? true : false,
result: 'success',
protocol: data.protocol,
sess: data.sess,
ip: data.ip
});
Expand Down Expand Up @@ -1367,6 +1368,7 @@ class UserHandler {
asp: asp._id,
aname: asp.description,
result: 'success',
protocol: data.protocol,
sess: data.sess,
ip: data.ip
});
Expand Down Expand Up @@ -3259,6 +3261,7 @@ class UserHandler {
await this.logAuthEvent(user, {
action: 'password change',
result: 'fail',
protocol: data.protocol,
sess: data.sess,
ip: data.ip
});
Expand Down Expand Up @@ -3372,6 +3375,7 @@ class UserHandler {
await this.logAuthEvent(user, {
action: 'password change',
result: 'success',
protocol: data.protocol,
sess: data.sess,
ip: data.ip
});
Expand Down