krypton 0.1.4 → 0.1.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4ea1222d75aae620b4e2be92a331c7923a7704b9
4
- data.tar.gz: c95adc5e3ead2573810d77028c68bcb4737197a4
3
+ metadata.gz: 173c51e066179dbd94a2562ed5f2bb3d77fb4b85
4
+ data.tar.gz: 48d3d1bfb54697117dd0a57ad04ccaf5792e715c
5
5
  SHA512:
6
- metadata.gz: 075b280c9a479242ca0b55bcea4ae096dd4af850277cf93d9cf6b53deacdb17ee72d6009f3f229c908dcd2ee3bb5dd31c9c5087412c9b8cf696e2ca889cb09ca
7
- data.tar.gz: 2db9f133398e3786e6d2a256ce8f07712fbf166b9b964b6ec5710288d59a4c8c1955525db147c1d4044c8676d8470730f3312c962fb40dfcf8bef292735fe7d7
6
+ metadata.gz: 537b61b1d63be44f4192ef74f7c2ba0831af95657b3386f66adf5287b8681879d3ce62c0e89f8a27118f6681d24db78e23efb8301efa3ec05d00804950ccddb2
7
+ data.tar.gz: ead0f9afb331fdcabd3c9e705602fad7395e3681da908656ad978b2b242c3c8dcf5967e40635009eb24904fa58de97082fe6b95959527fdcb10a37d11664e5f5
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- krypton (0.1.1)
4
+ krypton (0.1.4)
5
5
  aes
6
6
  colorize
7
7
  commander
data/README.md CHANGED
@@ -1,6 +1,4 @@
1
- # Krypton
2
-
3
- Simple encryption and decryption from the command line.
1
+ <p align="center"><img src="https://raw.githubusercontent.com/cbrnrd/krypton/master/img/krypton-readme-header.png"></p>
4
2
 
5
3
 
6
4
  ## Installation
@@ -81,6 +81,8 @@ while (opt = ARGV.shift) do
81
81
  puts "#{data + ' => '}#{Paint[result.strip, '#2ecc71']}"
82
82
  end
83
83
  exit 0
84
+ when 'uuid'
85
+ puts Paint[SecureRandom.uuid, '#2ecc71']
84
86
  else
85
87
  puts "#{opt} is not a valid action!"
86
88
  exit 1
@@ -2,6 +2,7 @@
2
2
  require 'base64'
3
3
  require 'optparse'
4
4
  require 'paint'
5
+ require 'securerandom'
5
6
 
6
7
  # lib files
7
8
  require_relative './core/constants.rb'
@@ -1,4 +1,4 @@
1
- VERSION = "0.1.4"
1
+ VERSION = "0.1.5"
2
2
  AUTHORS = {
3
3
  'Carter Brainerd' => '0xCB[at]protonmail[dot]com'
4
4
  }
@@ -1,13 +1,10 @@
1
1
  require 'digest'
2
2
 
3
3
  module Krypton
4
- class SHA
5
- def self.hash(data, raw=false)
6
- if raw
7
- return Digest::SHA256.hexdigest(data)
8
- else
9
- return Digest::SHA256.base64digest(data)
10
- end
11
- end
4
+ class SHA
5
+ def self.hash(data, raw=false)
6
+ return Digest::SHA256.hexdigest(data) if raw
7
+ return Digest::SHA256.base64digest(data)
12
8
  end
9
+ end
13
10
  end
@@ -7,6 +7,7 @@ TASKS_HELP =
7
7
  %Q{ encrypt Encrypt the message with the given key (AES).
8
8
  decrypt Decrypt the message with the given key (AES).
9
9
  hash Hash a given message with SHA256.
10
+ uuid Generate a random UUID.
10
11
 
11
12
  #{Paint['Examples', '#95a5a6']}
12
13
  #{Paint['$ krypton encrypt "mymessage" "mykey"', '#2ecc71']} #{Paint['=> ckhJWXcyTE1leENLOWpBQzJWbElMdz09Cg==', '#95a5a6']}
@@ -4,10 +4,6 @@ cd ..
4
4
 
5
5
  CURRENT_VERSION=$(cat lib/core/constants.rb | grep VERSION | cut -d '"' -f 2)
6
6
 
7
- TO_UPDATE=(
8
- lib/core/constants.rb
9
- )
10
7
 
11
8
  gem build krypton.gemspec
12
-
13
9
  gem install krypton-$CURRENT_VERSION.gem
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: krypton
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - cbrnrd
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-10-21 00:00:00.000000000 Z
11
+ date: 2018-10-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: colorize
@@ -129,13 +129,14 @@ files:
129
129
  - bin/console
130
130
  - bin/krypton
131
131
  - bin/setup
132
+ - img/krypton-readme-header.png
132
133
  - krypton.gemspec
133
134
  - lib/core.rb
134
135
  - lib/core/aes.rb
135
136
  - lib/core/constants.rb
136
137
  - lib/core/sha.rb
137
138
  - lib/core/text.rb
138
- - scripts/build-and-install.sh
139
+ - scripts/build_install_local.sh
139
140
  - scripts/release_and_build.sh
140
141
  homepage: https://github.com/cbrnrd/krypton
141
142
  licenses:
@@ -157,7 +158,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
157
158
  version: '0'
158
159
  requirements: []
159
160
  rubyforge_project:
160
- rubygems_version: 2.6.14
161
+ rubygems_version: 2.6.13
161
162
  signing_key:
162
163
  specification_version: 4
163
164
  summary: A command-line tool for easy encryption and decryption of data.