UNPKG

@aikidosec/firewall

Version:

Zen by Aikido is an embedded Web Application Firewall that autonomously protects Node.js apps against common and critical attacks

16 lines (15 loc) 561 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.externals = externals; const Hooks_1 = require("../agent/hooks/Hooks"); const protect_1 = require("../agent/protect"); function externals() { const wrappers = (0, protect_1.getWrappers)(); const hooks = new Hooks_1.Hooks(); wrappers.forEach((wrapper) => { wrapper.wrap(hooks); }); const packages = ["@aikidosec/firewall"].concat(hooks.getPackages().map((pkg) => pkg.getName())); // Remove duplicates return Array.from(new Set(packages)); }