@dadi/log-filter

Filter sensitive parameters from log files

Stats

stars 🌟issues ⚠️updated 🛠created 🐣size 🏋️‍♀️
00May 3, 2019Jun 29, 2018Minified + gzip package size for @dadi/log-filter in KB

Readme

Log Filter

Filter sensitive parameters from log files

npm (scoped) Coverage Status Build Status JavaScript Style Guide

Install

npm i @dadi/log-filter

Filter querystring parameters

const LogFilter = require('@dadi/log-filter')

let req = {
  url: '/profile?username=ed&password=octopus'
}

let filter = ['password']

let logFilter = new LogFilter(req, filter)
let output = logFilter.filterPath()

// produces /profile?username=ed&password=%5BFILTERED%5D

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.