secrets-cipher-base64 1.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.codeclimate.yml +25 -0
- data/.gitignore +12 -0
- data/.rspec +2 -0
- data/.rubocop.yml +1156 -0
- data/.travis.yml +13 -0
- data/Gemfile +6 -0
- data/LICENSE +22 -0
- data/MANAGING-KEYS.md +67 -0
- data/README.md +314 -0
- data/Rakefile +13 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/exe/keychain +38 -0
- data/exe/secrets +8 -0
- data/lib/secrets.rb +73 -0
- data/lib/secrets/app.rb +42 -0
- data/lib/secrets/app/cli.rb +197 -0
- data/lib/secrets/app/commands.rb +27 -0
- data/lib/secrets/app/commands/command.rb +55 -0
- data/lib/secrets/app/commands/delete_keychain_key.rb +15 -0
- data/lib/secrets/app/commands/encrypt_decrypt.rb +22 -0
- data/lib/secrets/app/commands/generate_key.rb +41 -0
- data/lib/secrets/app/commands/open_editor.rb +90 -0
- data/lib/secrets/app/commands/show_examples.rb +63 -0
- data/lib/secrets/app/commands/show_help.rb +13 -0
- data/lib/secrets/app/commands/show_version.rb +13 -0
- data/lib/secrets/app/keychain.rb +136 -0
- data/lib/secrets/app/outputs/to_file.rb +27 -0
- data/lib/secrets/app/outputs/to_stdout.rb +11 -0
- data/lib/secrets/app/password_handler.rb +39 -0
- data/lib/secrets/cipher_handler.rb +45 -0
- data/lib/secrets/configuration.rb +23 -0
- data/lib/secrets/data.rb +23 -0
- data/lib/secrets/data/decoder.rb +24 -0
- data/lib/secrets/data/encoder.rb +24 -0
- data/lib/secrets/data/wrapper_struct.rb +43 -0
- data/lib/secrets/errors.rb +27 -0
- data/lib/secrets/extensions/class_methods.rb +12 -0
- data/lib/secrets/extensions/instance_methods.rb +110 -0
- data/lib/secrets/version.rb +3 -0
- data/secrets-cipher-base64.gemspec +33 -0
- metadata +243 -0
@@ -0,0 +1,45 @@
|
|
1
|
+
require 'base64'
|
2
|
+
require_relative 'configuration'
|
3
|
+
|
4
|
+
module Secrets
|
5
|
+
#
|
6
|
+
# +CipherHandler+ contains cipher-related utilities necessary to create
|
7
|
+
# ciphers, and seed them with the salt or iV vector,
|
8
|
+
#
|
9
|
+
module CipherHandler
|
10
|
+
|
11
|
+
CREATE_CIPHER = ->(name) { ::OpenSSL::Cipher.new(name) }
|
12
|
+
|
13
|
+
CipherStruct = Struct.new(:cipher, :iv, :salt)
|
14
|
+
|
15
|
+
def create_cipher(direction:,
|
16
|
+
cipher_name:,
|
17
|
+
iv: nil,
|
18
|
+
salt: nil)
|
19
|
+
|
20
|
+
cipher = new_cipher(cipher_name)
|
21
|
+
cipher.send(direction)
|
22
|
+
iv ||= cipher.random_iv
|
23
|
+
cipher.iv = iv
|
24
|
+
CipherStruct.new(cipher, iv, salt)
|
25
|
+
end
|
26
|
+
|
27
|
+
def new_cipher(cipher_name)
|
28
|
+
CREATE_CIPHER.call(cipher_name)
|
29
|
+
end
|
30
|
+
|
31
|
+
def update_cipher(cipher, value)
|
32
|
+
data = cipher.update(value)
|
33
|
+
data << cipher.final
|
34
|
+
data
|
35
|
+
end
|
36
|
+
|
37
|
+
module ClassMethods
|
38
|
+
def create_private_key
|
39
|
+
key = CREATE_CIPHER.call(Secrets::Configuration.property(:private_key_cipher)).random_key
|
40
|
+
::Base64.urlsafe_encode64(key)
|
41
|
+
end
|
42
|
+
end
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
@@ -0,0 +1,23 @@
|
|
1
|
+
module Secrets
|
2
|
+
# Application configuration Singleton class.
|
3
|
+
# It's values are requested by the library upon encryption or
|
4
|
+
# decryption, or any other operation.
|
5
|
+
|
6
|
+
class Configuration
|
7
|
+
class << self
|
8
|
+
attr_accessor :config
|
9
|
+
|
10
|
+
def configure
|
11
|
+
self.config ||= Configuration.new
|
12
|
+
yield config if block_given?
|
13
|
+
end
|
14
|
+
|
15
|
+
def property(name)
|
16
|
+
self.config.send(name)
|
17
|
+
end
|
18
|
+
end
|
19
|
+
|
20
|
+
attr_accessor :data_cipher, :password_cipher, :private_key_cipher
|
21
|
+
attr_accessor :compression_enabled, :compression_level
|
22
|
+
end
|
23
|
+
end
|
data/lib/secrets/data.rb
ADDED
@@ -0,0 +1,23 @@
|
|
1
|
+
require_relative 'errors'
|
2
|
+
require 'base64'
|
3
|
+
require 'zlib'
|
4
|
+
|
5
|
+
require_relative 'data/wrapper_struct'
|
6
|
+
require_relative 'data/encoder'
|
7
|
+
require_relative 'data/decoder'
|
8
|
+
|
9
|
+
module Secrets
|
10
|
+
# This module is responsible for taking arbitrary data of any format, and safely compressing
|
11
|
+
# the result of `Marshal.dump(data)` using Zlib, and then doing `#urlsafe_encode64` encoding
|
12
|
+
# to convert it to a string,
|
13
|
+
module Data
|
14
|
+
def encode(data, compress = true)
|
15
|
+
Encoder.new(data, compress).data_encoded
|
16
|
+
end
|
17
|
+
|
18
|
+
def decode(data_encoded, compress = nil)
|
19
|
+
Decoder.new(data_encoded, compress).data
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
@@ -0,0 +1,24 @@
|
|
1
|
+
require_relative '../errors'
|
2
|
+
require 'base64'
|
3
|
+
require 'zlib'
|
4
|
+
module Secrets
|
5
|
+
module Data
|
6
|
+
class Decoder
|
7
|
+
attr_accessor :data, :data_encoded, :data
|
8
|
+
|
9
|
+
def initialize(data_encoded, compress)
|
10
|
+
self.data_encoded = data_encoded
|
11
|
+
self.data = Base64.urlsafe_decode64(data_encoded)
|
12
|
+
|
13
|
+
if compress.nil? || compress # auto-guess
|
14
|
+
self.data = begin
|
15
|
+
Zlib::Inflate.inflate(data)
|
16
|
+
rescue Zlib::Error => e
|
17
|
+
data
|
18
|
+
end
|
19
|
+
end
|
20
|
+
self.data = Marshal.load(data)
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
@@ -0,0 +1,24 @@
|
|
1
|
+
require 'base64'
|
2
|
+
require 'zlib'
|
3
|
+
|
4
|
+
require 'secrets/errors'
|
5
|
+
require 'secrets/configuration'
|
6
|
+
|
7
|
+
module Secrets
|
8
|
+
module Data
|
9
|
+
class Encoder
|
10
|
+
attr_accessor :data, :data_encoded
|
11
|
+
|
12
|
+
def initialize(data, compress)
|
13
|
+
self.data = data
|
14
|
+
self.data_encoded = Marshal.dump(data)
|
15
|
+
self.data_encoded = Zlib::Deflate.deflate(data_encoded, compression_level) if compress
|
16
|
+
self.data_encoded = Base64.urlsafe_encode64(data_encoded)
|
17
|
+
end
|
18
|
+
|
19
|
+
def compression_level
|
20
|
+
Secrets::Configuration.config.compression_level
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
@@ -0,0 +1,43 @@
|
|
1
|
+
require_relative '../errors'
|
2
|
+
module Secrets
|
3
|
+
module Data
|
4
|
+
class WrapperStruct < Struct.new(
|
5
|
+
:encrypted_data, # [Blob] Binary encrypted data (possibly compressed)
|
6
|
+
:iv, # [String] IV used to encrypt the data
|
7
|
+
:cipher_name, # [String] Name of the cipher used
|
8
|
+
:salt, # [Integer] For password-encrypted data this is the salt
|
9
|
+
:version, # [Integer] Version of the cipher used
|
10
|
+
:compress # [Boolean] indicates if compression should be applied
|
11
|
+
)
|
12
|
+
|
13
|
+
VERSION = 1
|
14
|
+
|
15
|
+
attr_accessor :compressed
|
16
|
+
|
17
|
+
def initialize(
|
18
|
+
encrypted_data:, # [Blob] Binary encrypted data (possibly compressed)
|
19
|
+
iv:, # [String] IV used to encrypt the data
|
20
|
+
cipher_name:, # [String] Name of the cipher used
|
21
|
+
salt: nil, # [Integer] For password-encrypted data this is the salt
|
22
|
+
version: VERSION, # [Integer] Version of the cipher used
|
23
|
+
compress: Secrets::Configuration.config.compression_enabled
|
24
|
+
)
|
25
|
+
super(encrypted_data, iv, cipher_name, salt, version, compress)
|
26
|
+
end
|
27
|
+
|
28
|
+
def config
|
29
|
+
Secrets::Configuration.config
|
30
|
+
end
|
31
|
+
|
32
|
+
def serialize
|
33
|
+
Marshal.dump(self)
|
34
|
+
end
|
35
|
+
|
36
|
+
def self.deserialize(data)
|
37
|
+
Marshal.load(data)
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
42
|
+
|
43
|
+
|
@@ -0,0 +1,27 @@
|
|
1
|
+
module Secrets
|
2
|
+
module Errors
|
3
|
+
# Exceptions superclass for this library.
|
4
|
+
class Secrets::Errors::Error < StandardError; end
|
5
|
+
|
6
|
+
# No secret has been provided for encryption or decryption
|
7
|
+
class NoPrivateKeyFound < Secrets::Errors::Error; end
|
8
|
+
class PasswordsDontMatch < Secrets::Errors::Error; end
|
9
|
+
class PasswordTooShort < Secrets::Errors::Error; end
|
10
|
+
class DataEncodingVersionMismatch< Secrets::Errors::Error; end
|
11
|
+
class EditorExitedAbnormally < Secrets::Errors::Error; end
|
12
|
+
class InvalidEncodingPrivateKey < Secrets::Errors::Error; end
|
13
|
+
class InvalidPasswordPrivateKey < Secrets::Errors::Error; end
|
14
|
+
class FileNotFound < Secrets::Errors::Error; end
|
15
|
+
class ExternalCommandError < Secrets::Errors::Error; end
|
16
|
+
|
17
|
+
# Method was called on an abstract class. Override such methods in
|
18
|
+
# subclasses, and use subclasses for instantiation of objects.
|
19
|
+
class AbstractMethodCalled < ArgumentError
|
20
|
+
def initialize(method, message = nil)
|
21
|
+
super("Abstract method call, on #{method}" + (message || ''))
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
|
27
|
+
|
@@ -0,0 +1,110 @@
|
|
1
|
+
require 'secrets'
|
2
|
+
require 'secrets/data'
|
3
|
+
require 'secrets/cipher_handler'
|
4
|
+
require 'openssl'
|
5
|
+
module Secrets
|
6
|
+
module Extensions
|
7
|
+
# This is the module that is really included in your class
|
8
|
+
# when you include +Secrets+.
|
9
|
+
#
|
10
|
+
# The module provides easy access to the encryption configuration
|
11
|
+
# via the +#encryption_config+ method, as well as two key
|
12
|
+
# methods: +#encr+ and +#decr+.
|
13
|
+
#
|
14
|
+
# Methods +#encr_password+ and +#decr_password+ provide a good
|
15
|
+
# example of how this module can be extended to provide more uses
|
16
|
+
# of various ciphers, by calling into the private +_encr+ and +_decr+
|
17
|
+
# methods.f
|
18
|
+
module InstanceMethods
|
19
|
+
include Secrets::Data
|
20
|
+
include Secrets::CipherHandler
|
21
|
+
|
22
|
+
def encryption_config
|
23
|
+
Secrets::Configuration.config
|
24
|
+
end
|
25
|
+
|
26
|
+
# Expects key to be a base64 encoded key
|
27
|
+
def encr(data, key, iv = nil)
|
28
|
+
_encr(data, encryption_config.data_cipher, iv) do |cipher_struct|
|
29
|
+
cipher_struct.cipher.key = decode_key(key)
|
30
|
+
end
|
31
|
+
end
|
32
|
+
|
33
|
+
# Expects key to be a base64 encoded key
|
34
|
+
def decr(encrypted_data, key, iv = nil)
|
35
|
+
_decr(encrypted_data, encryption_config.data_cipher, iv) do |cipher_struct|
|
36
|
+
cipher_struct.cipher.key = decode_key(key)
|
37
|
+
end
|
38
|
+
end
|
39
|
+
|
40
|
+
def encr_password(data, password, iv = nil)
|
41
|
+
_encr(data, encryption_config.password_cipher, iv) do |cipher_struct|
|
42
|
+
key, salt = _key_from_password(cipher_struct.cipher, password)
|
43
|
+
cipher_struct.cipher.key = key
|
44
|
+
cipher_struct.salt = salt
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
def decr_password(encrypted_data, password, iv = nil)
|
49
|
+
_decr(encrypted_data, encryption_config.password_cipher, iv) do |cipher_struct|
|
50
|
+
key, = _key_from_password(cipher_struct.cipher, password, cipher_struct.salt)
|
51
|
+
cipher_struct.cipher.key = key
|
52
|
+
end
|
53
|
+
end
|
54
|
+
|
55
|
+
private
|
56
|
+
|
57
|
+
def decode_key(encoded_key)
|
58
|
+
Base64.urlsafe_decode64(encoded_key)
|
59
|
+
end
|
60
|
+
|
61
|
+
def _key_from_password(cipher, password, salt = nil)
|
62
|
+
key_len = cipher.key_len
|
63
|
+
salt ||= OpenSSL::Random.random_bytes 16
|
64
|
+
iter = 20000
|
65
|
+
digest = OpenSSL::Digest::SHA256.new
|
66
|
+
key = OpenSSL::PKCS5.pbkdf2_hmac(password, salt, iter, key_len, digest)
|
67
|
+
return key, salt
|
68
|
+
end
|
69
|
+
|
70
|
+
# Expects key to be a base64 encoded key data
|
71
|
+
def _encr(data, cipher_name, iv = nil, &block)
|
72
|
+
data, compression_enabled = encode_incoming_data(data)
|
73
|
+
cipher_struct = create_cipher(direction: :encrypt,
|
74
|
+
cipher_name: cipher_name,
|
75
|
+
iv: iv)
|
76
|
+
|
77
|
+
yield cipher_struct if block_given?
|
78
|
+
|
79
|
+
encrypted_data = update_cipher(cipher_struct.cipher, data)
|
80
|
+
wrapper_struct = WrapperStruct.new(
|
81
|
+
encrypted_data: encrypted_data,
|
82
|
+
iv: cipher_struct.iv,
|
83
|
+
cipher_name: cipher_struct.cipher.name,
|
84
|
+
salt: cipher_struct.salt,
|
85
|
+
compress: !compression_enabled)
|
86
|
+
encode(wrapper_struct, false)
|
87
|
+
end
|
88
|
+
|
89
|
+
# Expects key to be a base64 encoded key data
|
90
|
+
def _decr(encoded_data, cipher_name, iv = nil, &block)
|
91
|
+
wrapper_struct = decode(encoded_data)
|
92
|
+
cipher_struct = create_cipher(cipher_name: cipher_name,
|
93
|
+
iv: wrapper_struct.iv,
|
94
|
+
direction: :decrypt,
|
95
|
+
salt: wrapper_struct.salt)
|
96
|
+
yield cipher_struct if block_given?
|
97
|
+
decode(update_cipher(cipher_struct.cipher, wrapper_struct.encrypted_data))
|
98
|
+
end
|
99
|
+
|
100
|
+
|
101
|
+
def encode_incoming_data(data)
|
102
|
+
compression_enabled = !data.respond_to?(:size) || (data.size > 100 && encryption_config.compression_enabled)
|
103
|
+
data = encode(data, compression_enabled)
|
104
|
+
[data, compression_enabled]
|
105
|
+
end
|
106
|
+
|
107
|
+
end
|
108
|
+
end
|
109
|
+
end
|
110
|
+
|
@@ -0,0 +1,33 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'secrets/version'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = 'secrets-cipher-base64'
|
8
|
+
spec.version = Secrets::VERSION
|
9
|
+
spec.authors = ['Konstantin Gredeskoul']
|
10
|
+
spec.email = %w(kigster@gmail.com)
|
11
|
+
|
12
|
+
spec.summary = %q{Simple tool to encrypt/decrypt data using symmetric aes-256-cbc encryption with a private key and an IV vector}
|
13
|
+
spec.description = %q{Store sensitive data safely as encrypted strings or entire files, using symmetric aes-256-cbc encryption/decryption with a secret key and an IV vector, and YAML-friendly base64-encoded encrypted result.}
|
14
|
+
spec.homepage = 'https://github.com/kigster/secrets-cipher-base64'
|
15
|
+
|
16
|
+
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
17
|
+
spec.bindir = 'exe'
|
18
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
19
|
+
spec.require_paths = ['lib']
|
20
|
+
|
21
|
+
spec.add_dependency 'require_dir', '~> 0.1'
|
22
|
+
spec.add_dependency 'colored2', '~> 2.0'
|
23
|
+
spec.add_dependency 'slop', '~> 4.3'
|
24
|
+
spec.add_dependency 'activesupport'
|
25
|
+
spec.add_dependency 'highline', '~> 1.7'
|
26
|
+
spec.add_dependency 'clipboard', '~> 1.1'
|
27
|
+
|
28
|
+
spec.add_development_dependency 'codeclimate-test-reporter'
|
29
|
+
spec.add_development_dependency 'bundler', '~> 1.12'
|
30
|
+
spec.add_development_dependency 'rake', '~> 10.0'
|
31
|
+
spec.add_development_dependency 'rspec', '~> 3.0'
|
32
|
+
spec.add_development_dependency 'yard', '~> 0.9'
|
33
|
+
end
|
metadata
ADDED
@@ -0,0 +1,243 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: secrets-cipher-base64
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 1.2.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Konstantin Gredeskoul
|
8
|
+
autorequire:
|
9
|
+
bindir: exe
|
10
|
+
cert_chain: []
|
11
|
+
date: 2016-08-10 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: require_dir
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0.1'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0.1'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: colored2
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '2.0'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '2.0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: slop
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '4.3'
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '4.3'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: activesupport
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :runtime
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: highline
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '1.7'
|
76
|
+
type: :runtime
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '1.7'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: clipboard
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '1.1'
|
90
|
+
type: :runtime
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - "~>"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '1.1'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: codeclimate-test-reporter
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - ">="
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0'
|
104
|
+
type: :development
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - ">="
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0'
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: bundler
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - "~>"
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '1.12'
|
118
|
+
type: :development
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - "~>"
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '1.12'
|
125
|
+
- !ruby/object:Gem::Dependency
|
126
|
+
name: rake
|
127
|
+
requirement: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - "~>"
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: '10.0'
|
132
|
+
type: :development
|
133
|
+
prerelease: false
|
134
|
+
version_requirements: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - "~>"
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: '10.0'
|
139
|
+
- !ruby/object:Gem::Dependency
|
140
|
+
name: rspec
|
141
|
+
requirement: !ruby/object:Gem::Requirement
|
142
|
+
requirements:
|
143
|
+
- - "~>"
|
144
|
+
- !ruby/object:Gem::Version
|
145
|
+
version: '3.0'
|
146
|
+
type: :development
|
147
|
+
prerelease: false
|
148
|
+
version_requirements: !ruby/object:Gem::Requirement
|
149
|
+
requirements:
|
150
|
+
- - "~>"
|
151
|
+
- !ruby/object:Gem::Version
|
152
|
+
version: '3.0'
|
153
|
+
- !ruby/object:Gem::Dependency
|
154
|
+
name: yard
|
155
|
+
requirement: !ruby/object:Gem::Requirement
|
156
|
+
requirements:
|
157
|
+
- - "~>"
|
158
|
+
- !ruby/object:Gem::Version
|
159
|
+
version: '0.9'
|
160
|
+
type: :development
|
161
|
+
prerelease: false
|
162
|
+
version_requirements: !ruby/object:Gem::Requirement
|
163
|
+
requirements:
|
164
|
+
- - "~>"
|
165
|
+
- !ruby/object:Gem::Version
|
166
|
+
version: '0.9'
|
167
|
+
description: Store sensitive data safely as encrypted strings or entire files, using
|
168
|
+
symmetric aes-256-cbc encryption/decryption with a secret key and an IV vector,
|
169
|
+
and YAML-friendly base64-encoded encrypted result.
|
170
|
+
email:
|
171
|
+
- kigster@gmail.com
|
172
|
+
executables:
|
173
|
+
- keychain
|
174
|
+
- secrets
|
175
|
+
extensions: []
|
176
|
+
extra_rdoc_files: []
|
177
|
+
files:
|
178
|
+
- ".codeclimate.yml"
|
179
|
+
- ".gitignore"
|
180
|
+
- ".rspec"
|
181
|
+
- ".rubocop.yml"
|
182
|
+
- ".travis.yml"
|
183
|
+
- Gemfile
|
184
|
+
- LICENSE
|
185
|
+
- MANAGING-KEYS.md
|
186
|
+
- README.md
|
187
|
+
- Rakefile
|
188
|
+
- bin/console
|
189
|
+
- bin/setup
|
190
|
+
- exe/keychain
|
191
|
+
- exe/secrets
|
192
|
+
- lib/secrets.rb
|
193
|
+
- lib/secrets/app.rb
|
194
|
+
- lib/secrets/app/cli.rb
|
195
|
+
- lib/secrets/app/commands.rb
|
196
|
+
- lib/secrets/app/commands/command.rb
|
197
|
+
- lib/secrets/app/commands/delete_keychain_key.rb
|
198
|
+
- lib/secrets/app/commands/encrypt_decrypt.rb
|
199
|
+
- lib/secrets/app/commands/generate_key.rb
|
200
|
+
- lib/secrets/app/commands/open_editor.rb
|
201
|
+
- lib/secrets/app/commands/show_examples.rb
|
202
|
+
- lib/secrets/app/commands/show_help.rb
|
203
|
+
- lib/secrets/app/commands/show_version.rb
|
204
|
+
- lib/secrets/app/keychain.rb
|
205
|
+
- lib/secrets/app/outputs/to_file.rb
|
206
|
+
- lib/secrets/app/outputs/to_stdout.rb
|
207
|
+
- lib/secrets/app/password_handler.rb
|
208
|
+
- lib/secrets/cipher_handler.rb
|
209
|
+
- lib/secrets/configuration.rb
|
210
|
+
- lib/secrets/data.rb
|
211
|
+
- lib/secrets/data/decoder.rb
|
212
|
+
- lib/secrets/data/encoder.rb
|
213
|
+
- lib/secrets/data/wrapper_struct.rb
|
214
|
+
- lib/secrets/errors.rb
|
215
|
+
- lib/secrets/extensions/class_methods.rb
|
216
|
+
- lib/secrets/extensions/instance_methods.rb
|
217
|
+
- lib/secrets/version.rb
|
218
|
+
- secrets-cipher-base64.gemspec
|
219
|
+
homepage: https://github.com/kigster/secrets-cipher-base64
|
220
|
+
licenses: []
|
221
|
+
metadata: {}
|
222
|
+
post_install_message:
|
223
|
+
rdoc_options: []
|
224
|
+
require_paths:
|
225
|
+
- lib
|
226
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
227
|
+
requirements:
|
228
|
+
- - ">="
|
229
|
+
- !ruby/object:Gem::Version
|
230
|
+
version: '0'
|
231
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
232
|
+
requirements:
|
233
|
+
- - ">="
|
234
|
+
- !ruby/object:Gem::Version
|
235
|
+
version: '0'
|
236
|
+
requirements: []
|
237
|
+
rubyforge_project:
|
238
|
+
rubygems_version: 2.5.1
|
239
|
+
signing_key:
|
240
|
+
specification_version: 4
|
241
|
+
summary: Simple tool to encrypt/decrypt data using symmetric aes-256-cbc encryption
|
242
|
+
with a private key and an IV vector
|
243
|
+
test_files: []
|