You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
376 B

  1. "use strict";
  2. const modb = require('mongoose');
  3. /**
  4. * BruteForce schema
  5. *
  6. * @type {<Mongoose.Schema>}
  7. */
  8. var bruteForceSchema = modb.Schema({
  9. _id: { type: String, index: 1 },
  10. data: {
  11. count: Number,
  12. lastRequest: Date,
  13. firstRequest: Date
  14. },
  15. expires: { type: Date, index: { expires: '1d' } }
  16. });
  17. module.exports = modb.model('Bruteforce', bruteForceSchema);