Browse Source

Manager LD_LIBRARY_PATH from bin

master
Nicolas Vinot 4 years ago
parent
commit
c3bb0213bd
13 changed files with 86 additions and 73 deletions
  1. 0
    19
      bin/check_https
  2. 1
    0
      bin/check_https
  3. 19
    0
      bin/check_https.rb
  4. 0
    21
      bin/check_https_alexa
  5. 1
    0
      bin/check_https_alexa
  6. 23
    0
      bin/check_https_alexa.rb
  7. 0
    17
      bin/check_smtp
  8. 1
    0
      bin/check_smtp
  9. 19
    0
      bin/check_smtp.rb
  10. 0
    16
      bin/check_xmpp
  11. 1
    0
      bin/check_xmpp
  12. 18
    0
      bin/check_xmpp.rb
  13. 3
    0
      bin/runner

+ 0
- 19
bin/check_https View File

@@ -1,19 +0,0 @@
1
-#!/usr/bin/env ruby
2
-$:.unshift 'lib'
3
-require 'logging'
4
-require 'cryptcheck'
5
-
6
-name = ARGV[0] || 'index'
7
-file = ::File.join 'output', "#{name}.yml"
8
-
9
-if ::File.exist? file
10
-	::CryptCheck::Tls::Https.analyze_from_file "output/#{name}.yml", "output/#{name}.html"
11
-else
12
-	::Logging.logger.root.appenders = ::Logging.appenders.stdout
13
-	::Logging.logger.root.level = :warn
14
-
15
-	server = ::CryptCheck::Tls::Https::Server.new(ARGV[0], ARGV[1] || 443)
16
-	p grade = ::CryptCheck::Tls::Https::Grade.new(server)
17
-end
18
-
19
-

+ 1
- 0
bin/check_https View File

@@ -0,0 +1 @@
1
+runner

+ 19
- 0
bin/check_https.rb View File

@@ -0,0 +1,19 @@
1
+#!/usr/bin/env ruby
2
+$:.unshift File.expand_path File.join File.dirname(__FILE__), '../lib'
3
+require 'rubygems'
4
+require 'bundler/setup'
5
+require 'logging'
6
+require 'cryptcheck'
7
+
8
+name = ARGV[0] || 'index'
9
+file = ::File.join 'output', "#{name}.yml"
10
+
11
+if ::File.exist? file
12
+	::CryptCheck::Tls::Https.analyze_from_file "output/#{name}.yml", "output/#{name}.html"
13
+else
14
+	::Logging.logger.root.appenders = ::Logging.appenders.stdout
15
+	::Logging.logger.root.level = :warn
16
+
17
+	server = ::CryptCheck::Tls::Https::Server.new(ARGV[0], ARGV[1] || 443)
18
+	p grade = ::CryptCheck::Tls::Https::Grade.new(server)
19
+end

+ 0
- 21
bin/check_https_alexa View File

@@ -1,21 +0,0 @@
1
-#!/usr/bin/env ruby
2
-$:.unshift 'lib'
3
-require 'logging'
4
-require 'cryptcheck'
5
-
6
-GROUP_NAME = 'Top 100 Alexa'
7
-
8
-::Logging.logger.root.appenders = ::Logging.appenders.stdout
9
-::Logging.logger.root.level = :error
10
-
11
-hosts = []
12
-::File.open('top-1m.csv', 'r') do |file|
13
-	i = 0
14
-	while line = file.gets
15
-		hosts << [GROUP_NAME, line.strip.split(',')[1]]
16
-		i += 1
17
-		break if i == 100
18
-	end
19
-end
20
-
21
-::CryptCheck::Tls::Https.analyze hosts, 'output/alexa.html'

+ 1
- 0
bin/check_https_alexa View File

@@ -0,0 +1 @@
1
+runner

+ 23
- 0
bin/check_https_alexa.rb View File

@@ -0,0 +1,23 @@
1
+#!/usr/bin/env ruby
2
+$:.unshift File.expand_path File.join File.dirname(__FILE__), '../lib'
3
+require 'rubygems'
4
+require 'bundler/setup'
5
+require 'logging'
6
+require 'cryptcheck'
7
+
8
+GROUP_NAME = 'Top 100 Alexa'
9
+
10
+::Logging.logger.root.appenders = ::Logging.appenders.stdout
11
+::Logging.logger.root.level = :error
12
+
13
+hosts = []
14
+::File.open('top-1m.csv', 'r') do |file|
15
+	i = 0
16
+	while line = file.gets
17
+		hosts << [GROUP_NAME, line.strip.split(',')[1]]
18
+		i += 1
19
+		break if i == 100
20
+	end
21
+end
22
+
23
+::CryptCheck::Tls::Https.analyze hosts, 'output/alexa.html'

+ 0
- 17
bin/check_smtp View File

@@ -1,17 +0,0 @@
1
-#!/usr/bin/env ruby
2
-$:.unshift 'lib'
3
-require 'logging'
4
-require 'cryptcheck'
5
-
6
-name = ARGV[0]
7
-unless name
8
-	::CryptCheck::Tls::Smtp.analyze_from_file 'output/smtp.yml', 'output/smtp.html'
9
-else
10
-	::Logging.logger.root.appenders = ::Logging.appenders.stdout
11
-	::Logging.logger.root.level = :warn
12
-
13
-	server = ::CryptCheck::Tls::Smtp::Server.new(ARGV[0], ARGV[1] || 25)
14
-	p grade = ::CryptCheck::Tls::Smtp::Grade.new(server)
15
-end
16
-
17
-

+ 1
- 0
bin/check_smtp View File

@@ -0,0 +1 @@
1
+runner

+ 19
- 0
bin/check_smtp.rb View File

@@ -0,0 +1,19 @@
1
+#!/usr/bin/env ruby
2
+$:.unshift File.expand_path File.join File.dirname(__FILE__), '../lib'
3
+require 'rubygems'
4
+require 'bundler/setup'
5
+require 'logging'
6
+require 'cryptcheck'
7
+
8
+name = ARGV[0]
9
+unless name
10
+	::CryptCheck::Tls::Smtp.analyze_from_file 'output/smtp.yml', 'output/smtp.html'
11
+else
12
+	::Logging.logger.root.appenders = ::Logging.appenders.stdout
13
+	::Logging.logger.root.level = :warn
14
+
15
+	server = ::CryptCheck::Tls::Smtp::Server.new(ARGV[0], ARGV[1] || 25)
16
+	p grade = ::CryptCheck::Tls::Smtp::Grade.new(server)
17
+end
18
+
19
+

+ 0
- 16
bin/check_xmpp View File

@@ -1,16 +0,0 @@
1
-#!/usr/bin/env ruby
2
-$:.unshift 'lib'
3
-require 'logging'
4
-require 'cryptcheck'
5
-
6
-name = ARGV[0]
7
-if name
8
-	::Logging.logger.root.appenders = ::Logging.appenders.stdout
9
-	::Logging.logger.root.level = :warn
10
-
11
-	server = ::CryptCheck::Tls::Xmpp::Server.new(name, ARGV[1] || :s2s)
12
-	p grade = ::CryptCheck::Tls::Xmpp::Grade.new(server)
13
-else
14
-	::CryptCheck::Tls::Xmpp.analyze_from_file 'output/xmpp.yml', 'output/xmpp.html'
15
-end
16
-

+ 1
- 0
bin/check_xmpp View File

@@ -0,0 +1 @@
1
+runner

+ 18
- 0
bin/check_xmpp.rb View File

@@ -0,0 +1,18 @@
1
+#!/usr/bin/env ruby
2
+$:.unshift File.expand_path File.join File.dirname(__FILE__), '../lib'
3
+require 'rubygems'
4
+require 'bundler/setup'
5
+require 'logging'
6
+require 'cryptcheck'
7
+
8
+name = ARGV[0]
9
+if name
10
+	::Logging.logger.root.appenders = ::Logging.appenders.stdout
11
+	::Logging.logger.root.level = :warn
12
+
13
+	server = ::CryptCheck::Tls::Xmpp::Server.new(name, ARGV[1] || :s2s)
14
+	p grade = ::CryptCheck::Tls::Xmpp::Grade.new(server)
15
+else
16
+	::CryptCheck::Tls::Xmpp.analyze_from_file 'output/xmpp.yml', 'output/xmpp.html'
17
+end
18
+

+ 3
- 0
bin/runner View File

@@ -0,0 +1,3 @@
1
+#!/bin/bash
2
+DIR="$(readlink -m "$(dirname "$0")")"
3
+LD_LIBRARY_PATH="${DIR}/../lib" "${0}.rb" $*

Loading…
Cancel
Save