openssl-extensions 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,27 @@
|
|
1
|
+
require 'openssl-extensions/ssl'
|
2
|
+
require 'openssl-extensions/x509/certificate_chain'
|
3
|
+
|
4
|
+
module OpenSSLExtensions::SSL::SSLSocket
|
5
|
+
|
6
|
+
def self.included(base)
|
7
|
+
base.send(:alias_method,
|
8
|
+
:peer_cert_chain_without_openssl_extension,
|
9
|
+
:peer_cert_chain)
|
10
|
+
base.send(:alias_method,
|
11
|
+
:peer_cert_chain,
|
12
|
+
:peer_cert_chain_with_openssl_extension)
|
13
|
+
end
|
14
|
+
|
15
|
+
##
|
16
|
+
# Rather than returning the default, unsorted Array of
|
17
|
+
# OpenSSL::X509::Certificate instances, this will filter that
|
18
|
+
# Array through the OpenSSLExtensions::X509::CertificateChain.
|
19
|
+
#
|
20
|
+
def peer_cert_chain_with_openssl_extension
|
21
|
+
OpenSSLExtensions::X509::CertificateChain.
|
22
|
+
new(peer_cert, peer_cert_chain_without_openssl_extension)
|
23
|
+
end
|
24
|
+
|
25
|
+
end
|
26
|
+
|
27
|
+
OpenSSL::SSL::SSLSocket.send(:include, OpenSSLExtensions::SSL::SSLSocket)
|
metadata
CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
segments:
|
6
6
|
- 0
|
7
7
|
- 0
|
8
|
-
-
|
9
|
-
version: 0.0.
|
8
|
+
- 3
|
9
|
+
version: 0.0.3
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Nathaniel Bibler
|
@@ -14,7 +14,7 @@ autorequire:
|
|
14
14
|
bindir: bin
|
15
15
|
cert_chain: []
|
16
16
|
|
17
|
-
date: 2010-10-
|
17
|
+
date: 2010-10-05 00:00:00 -04:00
|
18
18
|
default_executable:
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
@@ -44,6 +44,8 @@ extra_rdoc_files: []
|
|
44
44
|
|
45
45
|
files:
|
46
46
|
- lib/openssl-extensions/all.rb
|
47
|
+
- lib/openssl-extensions/ssl/ssl_socket.rb
|
48
|
+
- lib/openssl-extensions/ssl.rb
|
47
49
|
- lib/openssl-extensions/version.rb
|
48
50
|
- lib/openssl-extensions/x509/authority_key_identifier.rb
|
49
51
|
- lib/openssl-extensions/x509/certificate.rb
|