wikijs-fork/models/bruteforce.js

18 lines
349 B
JavaScript
Raw Normal View History

"use strict";
/**
* BruteForce schema
*
* @type {<Mongoose.Schema>}
*/
2016-11-21 01:09:50 +00:00
var bruteForceSchema = Mongoose.Schema({
_id: { type: String, index: 1 },
data: {
count: Number,
lastRequest: Date,
firstRequest: Date
},
expires: { type: Date, index: { expires: '1d' } }
});
2016-11-21 01:09:50 +00:00
module.exports = Mongoose.model('Bruteforce', bruteForceSchema);