certutil 0.1.0 → 0.2.0

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: 337ac9e815212f52c227e2b4d3ac7da2fda87640
4
- data.tar.gz: 022b56ab7537b0a0e167d129ac07cc9a5cba9f75
3
+ metadata.gz: a1a1245a6f2d280e509d8fd607b95f876ab73ab4
4
+ data.tar.gz: e44b5eae0ac889a4bbbe51b9ad20d59b3d705978
5
5
  SHA512:
6
- metadata.gz: 99f5d062fa56b786613779a8d8d5b5dc8a9c8d8757c45316d2944367999327abc21ca87b1b6a7dc41695fa41727c2715b759f9ed1147d87762431e4809152995
7
- data.tar.gz: 3f51c62de7017d20340ec87733eef9a92f16ea30f8ca1d1b9c610c986fc50d6217544a6160c5977b9ff3cdd221602dd759e6a8b285f075f739ddf3dd690805ba
6
+ metadata.gz: 6bdd26f01ebfb72eabfec86579ae8d066c7071457c200841006a1492b0df1f8f1a76a3e7bc36e1c9d6a33ec8c9732cd5ae23fc7065a53652dea435a00664a471
7
+ data.tar.gz: 9f5f019ff29ba82d2502e52717757d6ecc37cf03881a8e869b6682f9a0670756c16e34789cfe44b925d22bd8de1159252af7cd978629fb347771372134e22a5d
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- certutil (0.1.0)
4
+ certutil (0.2.0)
5
5
  methadone (~> 1.3.2)
6
6
 
7
7
  GEM
data/bin/certutil CHANGED
@@ -16,6 +16,8 @@ class App
16
16
  debug "from bin, wd is #{Dir.pwd}"
17
17
 
18
18
  @cp = CertificateParser.new_from_input(source)
19
+ puts "cp is #{@cp}, a #{@cp.class}"
20
+ @cp.flipit! if options[:reverse]
19
21
  #if options["input"]
20
22
  #@cp = CertificateParser.new_from_file(File.expand_path(options["input"]))
21
23
  #elsif options["hostname"]
@@ -56,6 +58,7 @@ class App
56
58
  on("--output FORMAT", "-o", "Write out results to the current directory (formats are crt or txt (decoded)")
57
59
  on("--split", "-s", "Split multiple certs into separate files for writing")
58
60
  on("--mute", "-m", "Mute output")
61
+ on("--reverse", "-r", "Reverse the order of multiple certs (CA first, domain last)")
59
62
 
60
63
  # options[flag] will contain VAL
61
64
  #
@@ -43,6 +43,10 @@ class CertificateParser
43
43
  def certs
44
44
  @certs ||= split_input
45
45
  end
46
+
47
+ def flipit!
48
+ @certs = certs.reverse
49
+ end
46
50
 
47
51
  def decoded
48
52
  debug "lazy loading decoded..."
@@ -1,3 +1,3 @@
1
1
  module Certutil
2
- VERSION = "0.1.0"
2
+ VERSION = "0.2.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: certutil
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Chad Bailey
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-04-01 00:00:00.000000000 Z
11
+ date: 2014-09-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler