Add blackhole routes to common exploit crawlers
This commit is contained in:
parent
2da5dd313c
commit
7a4e1324ee
3
app.js
3
app.js
@ -26,6 +26,9 @@ const oneDay = 86400000;
|
||||
app.use(compress());
|
||||
app.use(express.static(__dirname + '/build'));
|
||||
|
||||
// Lets try and slow down some of those exploit crawlers
|
||||
app.use("/", require('./filterRoutes'))
|
||||
|
||||
var md = markdown({html: true});
|
||||
md.parser.use(emoji);
|
||||
|
||||
|
10
filterRoutes.js
Normal file
10
filterRoutes.js
Normal file
@ -0,0 +1,10 @@
|
||||
const express = require('express');
|
||||
|
||||
const router = express.Router();
|
||||
router.all('(/*)?/wp-admin/', function (req, res) {});
|
||||
router.all('*?/xmlrpc.php', function (req, res) {});
|
||||
router.all('(/*)?/wp-includes/(*)?', function (req, res) {});
|
||||
router.all('/.git/*?', function (req, res) {});
|
||||
router.all('/wp-login.php', function (req, res) {});
|
||||
|
||||
module.exports = router
|
Loading…
Reference in New Issue
Block a user