An open API service indexing awesome lists of open source software.

https://github.com/one-com/express-validate-ip

Validate the request IP against a whitelist
https://github.com/one-com/express-validate-ip

Last synced: about 1 year ago
JSON representation

Validate the request IP against a whitelist

Awesome Lists containing this project

README

          

# express-validate-ip

## installation

```
$ npm install express-validate-ip
```

## Usage

```js

const express = require('express');
const expressValidateIp = require('express-validate-ip');

const allowList = [
'127.0.0.1',
'10.0.0.0/16'
];

const app = express();

app.use(expressValidateIp(allowList));

// ...
```

## License

MIT