npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

cyber-shield-express

v1.0.2

Published

CyberShield WAF Agent for Express.js — Real-time web application firewall powered by MERN Cloud AI engine. Protects against SQL injection, XSS, brute-force, and more.

Readme

CyberShield WAF Plugin for Express.js

CyberShield WAF Plugin is a real-time web application firewall (WAF) middleware for Express.js applications. Powered by the MERN Cloud AI engine, it provides robust protection against common web vulnerabilities

Installation

You can install the CyberShield Plugin via npm or yarn.

Using npm

npm install cyber-shield-express

Using yarn

yarn add cyber-shield-express

Note: This package requires Node.js 14.0.0 or higher and Express 4.0.0 or higher.


Basic Usage

To integrate the CyberShield WAF into your Express application, simply import the agent, initialize it with your configuration credentials, and add it as a middleware.

import cyberShield from "cyber-shield-express";


const app = express();

// 1. Initialize CyberShield Agent
cyberShield.init({
  apiKey:       process.env.CYBERSHIELD_API_KEY,
  siteUrl:      process.env.CYBERSHIELD_SITE_URL,
  emailAddress: process.env.CYBERSHIELD_EMAIL,
});
// 2. Attach the WAF middleware globally
// Ensure you place this BEFORE your route definitions so requests are scanned.
app.use(cyberShield.waf);

// Example route
app.get('/', (req, res) => {
  res.send('Your application is protected by CyberShield!');
});

const PORT = process.env.PORT || 3000;
app.listen(PORT, () => {
  console.log(`Server running on port ${PORT}`);
});

Environment Variables

All credentials must be stored in a .env file at the root of your project — never hardcoded in source code.

1. Install dotenv

npm install dotenv

2. Create a .env file

# .env  (never commit this file — add it to .gitignore)
CYBERSHIELD_API_KEY=your_cybershield_api_key
CYBERSHIELD_SITE_URL=https://your-domain.com
[email protected]
CYBERSHIELD_API_URL=https://your-mern-engine-url.com

3. Load .env at the very top of your entry file

require('dotenv').config(); // Must be the FIRST line

const express    = require('express');
const cyberShield = require('cyber-shield-express');

Important: Add .env to your .gitignore to prevent secrets from being committed.

# .gitignore
.env

Configuration Options

When calling cyberShield.init(config), you can pass the following properties in the config object:

| Option | Type | Required | Description | |--------|------|----------|-------------| | apiKey | string | Yes | Your unique CyberShield API Key. | | siteUrl | string | Yes | The base URL of the site being protected. | | emailAddress | string | Yes | Administrator email address for alert notifications. |

Support & Issues

For issues and feature requests, please visit the GitHub repository or contact SECURAS.