Socket
Socket
Sign inDemoInstall

key-scramble

Package Overview
Dependencies
0
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    key-scramble

scrambles strings e.g. keys, secrets, tokens


Version published
Maintainers
1
Install size
2.40 kB
Created

Readme

Source

Key Scramble

Scramble keys, secrets and tokens.

In case you want to document something which contains e.g. a client id and client secret, you can blur a screenshot or just 'key-scramble' and replace it. In this case the structure of the key is available and the user of your document will be happy.

Example

let keyScramble = require('./key-scramble.js');
console.log("secretKey123456", keyScramble("secretKey123456"));
console.log("userId_20181031", keyScramble("userId_20181031", true));

Command Line

./bin/key-scramble key [--resetNumber]

With the resetNumber parameter all numbers will be changed to '9' and other characters aren't touched.

In case your key contains one ore more ! characters, bash will show an error message event not found. Turn off history with following command:

set +H

Keywords

FAQs

Last updated on 01 Nov 2018

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc