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

yaml-crypt

Package Overview
Dependencies
Maintainers
1
Versions
37
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

yaml-crypt - npm Package Compare versions

Comparing version 0.7.0 to 0.7.1

88

bin/yaml-crypt-cli.js

@@ -44,3 +44,3 @@ #!/usr/bin/env node

try {
run(null, cfg, {});
run(undefined, cfg, {});
} catch (e) {

@@ -72,5 +72,5 @@ handleError(e);

if (status === 0) {
this._printMessage(message);
this._print_message(message);
} else {
this._printMessage(message, process.stderr);
this._print_message(message, process.stderr);
}

@@ -89,3 +89,3 @@ }

_printMessage(message, stream) {
_print_message(message, stream) {
if (message) {

@@ -103,23 +103,27 @@ if (options.stdout) {

prog: module.exports.name,
version: module.exports.version,
addHelp: true,
add_help: true,
description: module.exports.description
});
parser.addArgument(["--debug"], {
action: "storeTrue",
parser.add_argument("-v", "--version", {
action: "version",
version: module.exports.version,
help: "Show version number and exit"
});
parser.add_argument("--debug", {
action: "store_true",
help: "Show debugging output"
});
parser.addArgument(["-e", "--encrypt"], {
action: "storeTrue",
parser.add_argument("-e", "--encrypt", {
action: "store_true",
help: "Encrypt data"
});
parser.addArgument(["-d", "--decrypt"], {
action: "storeTrue",
parser.add_argument("-d", "--decrypt", {
action: "store_true",
help: "Decrypt data"
});
parser.addArgument(["--generate-key"], {
action: "storeTrue",
parser.add_argument("--generate-key", {
action: "store_true",
help: "Generate a new random key. Use -a to specify the algorithm"
});
parser.addArgument(["--write-key"], {
parser.add_argument("--write-key", {
metavar: "<name>",

@@ -129,3 +133,3 @@ help:

});
parser.addArgument(["-k"], {
parser.add_argument("-k", {
action: "append",

@@ -136,3 +140,3 @@ metavar: "<key>",

});
parser.addArgument(["-K"], {
parser.add_argument("-K", {
metavar: "<key>",

@@ -142,3 +146,3 @@ help:

});
parser.addArgument(["-a", "--algorithm"], {
parser.add_argument("-a", "--algorithm", {
metavar: "<algorithm>",

@@ -148,13 +152,13 @@ help:

});
parser.addArgument(["-E", "--edit"], {
action: "storeTrue",
parser.add_argument("-E", "--edit", {
action: "store_true",
help:
"Open an editor for the given files, transparently decrypting and encrypting the file content"
});
parser.addArgument(["-B", "--base64"], {
action: "storeTrue",
parser.add_argument("-B", "--base64", {
action: "store_true",
help:
"Encode values using Base64 encoding before encrypting and decode values after decrypting"
});
parser.addArgument(["--path"], {
parser.add_argument("--path", {
metavar: "<yaml-path>",

@@ -164,3 +168,3 @@ help:

});
parser.addArgument(["--query"], {
parser.add_argument("--query", {
metavar: "<yaml-query>",

@@ -170,30 +174,30 @@ help:

});
parser.addArgument(["--raw"], {
action: "storeTrue",
parser.add_argument("--raw", {
action: "store_true",
help: "Encrypt/decrypt raw messages instead of YAML documents"
});
parser.addArgument(["-D", "--dir"], {
action: "storeTrue",
parser.add_argument("-D", "--dir", {
action: "store_true",
help:
"Allows to pass directories as input, process all files within the given directories (non-recursive)"
});
parser.addArgument(["-R", "--recursive"], {
action: "storeTrue",
parser.add_argument("-R", "--recursive", {
action: "store_true",
help:
"Allows to pass directories as input, process all files within the given directories and subdirectories recursively"
});
parser.addArgument(["--continue"], {
action: "storeTrue",
parser.add_argument("--continue", {
action: "store_true",
help:
"Continue processing even when encryption/decryption of one or more files failed"
});
parser.addArgument(["--keep"], {
action: "storeTrue",
parser.add_argument("--keep", {
action: "store_true",
help: "Keep the original files after encryption/decryption"
});
parser.addArgument(["-f", "--force"], {
action: "storeTrue",
parser.add_argument("-f", "--force", {
action: "store_true",
help: "Overwrite existing files"
});
parser.addArgument(["file"], {
parser.add_argument("file", {
nargs: "*",

@@ -207,3 +211,3 @@ metavar: "<file>",

) {
parser.addArgumentGroup({
parser.add_argument_group({
title: "Configuration file",

@@ -217,3 +221,3 @@ description:

});
parser.addArgumentGroup({
parser.add_argument_group({
title: "Key sources",

@@ -228,3 +232,3 @@ description:

});
parser.addArgumentGroup({
parser.add_argument_group({
title: "Decryption keys",

@@ -238,3 +242,3 @@ description:

});
parser.addArgumentGroup({
parser.add_argument_group({
title: "Encryption keys",

@@ -252,3 +256,3 @@ description:

}
const args = parser.parseArgs(argv);
const args = parser.parse_args(argv);
if (args.encrypt && args.decrypt) {

@@ -255,0 +259,0 @@ throw new UsageError("cannot combine --encrypt and --decrypt!");

{
"name": "yaml-crypt",
"version": "0.7.0",
"version": "0.7.1",
"description": "Encrypt and decrypt YAML documents",

@@ -26,3 +26,3 @@ "license": "MIT",

"dependencies": {
"argparse": "^1.0.7",
"argparse": "^2.0.1",
"branca": "^0.3.0",

@@ -38,6 +38,6 @@ "fernet": "^0.3.1",

"coveralls": "^3.1.0",
"eslint": "^7.1.0",
"mocha": "^7.2.0",
"eslint": "^7.9.0",
"mocha": "^8.1.3",
"nyc": "^15.1.0",
"prettier": "^2.0.5"
"prettier": "^2.1.2"
},

@@ -44,0 +44,0 @@ "prettier": {

Sorry, the diff of this file is not supported yet

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