Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

node-cipher

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-cipher - npm Package Compare versions

Comparing version 2.4.4 to 2.4.5

24

bin/cipher.js

@@ -7,14 +7,4 @@ #!/usr/bin/env node

var xcrypt = require('./xcrypt');
var list = require('./list');
/**
* List valid commands.
*/
var commands = [
'encrypt',
'decrypt',
'list'
];
/**
* Base command line interface.

@@ -29,4 +19,4 @@ */

.command('decrypt', 'Decrypt a given file', xcrypt)
.command('list', 'List all available cipher algorithms', list)
.epilogue('For more information, visit http://github.com/nathanbuchar/node-cipher')
.describe('l', 'List all available cipher algorithms')
.alias('l', 'list')
.alias('h', 'help')

@@ -36,9 +26,15 @@ .alias('v', 'version')

.wrap(74)
.epilogue('For more information, visit http://github.com/nathanbuchar/node-cipher')
.argv;
/**
* Show help if the chosen command is invalid.
* Show help menu if `list` is not chosen and the specified command is invalid.
*/
if (commands.indexOf(argv._[0]) < 0) {
if (argv.list) {
var algorithmArray = nodecipher.list();
var algorithmList = algorithmArray.join(', ');
console.log(algorithmList);
} else if (['encrypt', 'decrypt'].indexOf(argv._[0]) < 0) {
yargs.showHelp();
}

@@ -42,6 +42,6 @@ #!/usr/bin/env node

})
.epilogue('For more information, visit http://github.com/nathanbuchar/node-cipher')
.alias('h', 'help')
.help('h')
.wrap(74)
.epilogue('For more information, visit http://github.com/nathanbuchar/node-cipher')
.argv;

@@ -48,0 +48,0 @@

{
"name": "node-cipher",
"version": "2.4.4",
"version": "2.4.5",
"description": "Encrypt or decrypt sensitive files to allow use in public source control.",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -65,3 +65,3 @@ # node-cipher

```
Usage: nodecipher <command> {options}
Usage: nodecipher <command>

@@ -73,6 +73,7 @@

decrypt Decrypt a given file.
list List all available cipher options.
Options:
--list, -l List all available cipher algorithms.
--help, -h Show the help menu.

@@ -105,3 +106,3 @@

specified during encryption. By default, the encryption algorithm is set to
`cast5-cbc`. Use `nodecipher list` to see a list of available cipher
`cast5-cbc`. Use `nodecipher -l` to see a list of available cipher
algorithms. (Optional; Default: cast5-cbc)

@@ -161,3 +162,3 @@

|`password`|`string`|The encryption password. Unlike the command line interface, this MUST be specified.|Yes|
|`algorithm`|`string`|The algorithm to use. Use `$ nodecipher list` to see a list of available cipher algorithms. Default: `cast5-cbc`|No|
|`algorithm`|`string`|The algorithm to use. Use `nodecipher -l` to see a list of available cipher algorithms. Default: `cast5-cbc`|No|

@@ -164,0 +165,0 @@

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc