openssl_pkcs8 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,5 @@
1
+ lib/**/*.rb
2
+ bin/*
3
+ -
4
+ features/**/*.feature
5
+ LICENSE.txt
data/Gemfile ADDED
@@ -0,0 +1,5 @@
1
+ source "http://rubygems.org"
2
+
3
+ group :development do
4
+ gem "jeweler", "~> 1.6.4"
5
+ end
@@ -0,0 +1,20 @@
1
+ Copyright (c) 2012 Scott Tadman, The Working Group Inc.
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining
4
+ a copy of this software and associated documentation files (the
5
+ "Software"), to deal in the Software without restriction, including
6
+ without limitation the rights to use, copy, modify, merge, publish,
7
+ distribute, sublicense, and/or sell copies of the Software, and to
8
+ permit persons to whom the Software is furnished to do so, subject to
9
+ the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be
12
+ included in all copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
15
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
17
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
18
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
19
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,19 @@
1
+ = openssl-pkcs8
2
+
3
+ This adds PKCS8 compliant key export to the OpenSSL::PKey::RSA library that
4
+ is part of standard Ruby distributions.
5
+
6
+ Example:
7
+
8
+ key = OpenSSL::PKey::RSA.new(1024)
9
+
10
+ key.to_pem_pkcs8
11
+ # => "-----BEGIN PRIVATE KEY----- ..."
12
+
13
+ == Copyright
14
+
15
+ The contents of openssl_pkcs8.c is mostly taken from the Ruby distribution and
16
+ is licensed under exactly the same terms as the original.
17
+
18
+ The remainder is (C) 2012 Scott Tadman, The Working Group Inc. under the MIT
19
+ License.
@@ -0,0 +1,28 @@
1
+ # encoding: utf-8
2
+
3
+ require 'rubygems'
4
+ require 'bundler'
5
+ begin
6
+ Bundler.setup(:default, :development)
7
+ rescue Bundler::BundlerError => e
8
+ $stderr.puts e.message
9
+ $stderr.puts "Run `bundle install` to install missing gems"
10
+ exit e.status_code
11
+ end
12
+
13
+ require 'rake'
14
+ require 'jeweler'
15
+
16
+ Jeweler::Tasks.new do |gem|
17
+ # gem is a Gem::Specification... see http://docs.rubygems.org/read/chapter/20 for more options
18
+ gem.name = "openssl_pkcs8"
19
+ gem.homepage = "http://github.com/twg/openssl_pkcs8"
20
+ gem.license = "MIT"
21
+ gem.summary = %Q{OpenSSL RSA PKCS8 Extension}
22
+ gem.description = %Q{Adds PKCS8 key format support to OpenSSL::PKey::RSA}
23
+ gem.email = "github@tadman.ca"
24
+ gem.authors = [ "Scott Tadman" ]
25
+ # dependencies defined in Gemfile
26
+ end
27
+
28
+ Jeweler::RubygemsDotOrgTasks.new
@@ -0,0 +1,11 @@
1
+ require 'mkmf'
2
+
3
+ extension_name = 'openssl_pkcs8'
4
+
5
+ dir_config(extension_name)
6
+
7
+ have_header("openssl/ssl.h")
8
+ %w[crypto libeay32].any? {|lib| have_library(lib, "OpenSSL_add_all_digests")}
9
+ %w[ssl ssleay32].any? {|lib| have_library(lib, "SSL_library_init")}
10
+
11
+ create_makefile(extension_name)
@@ -0,0 +1,11 @@
1
+ require 'test/unit'
2
+
3
+ $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
4
+ $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'ext'))
5
+ $LOAD_PATH.unshift(File.dirname(__FILE__))
6
+
7
+ require 'openssl_pkcs8'
8
+
9
+ class Test::Unit::TestCase
10
+ # ...
11
+ end
metadata ADDED
@@ -0,0 +1,66 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: openssl_pkcs8
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ prerelease:
6
+ platform: ruby
7
+ authors:
8
+ - Scott Tadman
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2012-01-16 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: jeweler
16
+ requirement: &2153405400 !ruby/object:Gem::Requirement
17
+ none: false
18
+ requirements:
19
+ - - ~>
20
+ - !ruby/object:Gem::Version
21
+ version: 1.6.4
22
+ type: :development
23
+ prerelease: false
24
+ version_requirements: *2153405400
25
+ description: Adds PKCS8 key format support to OpenSSL::PKey::RSA
26
+ email: github@tadman.ca
27
+ executables: []
28
+ extensions:
29
+ - ext/openssl_pkcs8/extconf.rb
30
+ extra_rdoc_files:
31
+ - LICENSE.txt
32
+ - README.rdoc
33
+ files:
34
+ - .document
35
+ - Gemfile
36
+ - LICENSE.txt
37
+ - README.rdoc
38
+ - Rakefile
39
+ - test/helper.rb
40
+ - ext/openssl_pkcs8/extconf.rb
41
+ homepage: http://github.com/twg/openssl_pkcs8
42
+ licenses:
43
+ - MIT
44
+ post_install_message:
45
+ rdoc_options: []
46
+ require_paths:
47
+ - lib
48
+ required_ruby_version: !ruby/object:Gem::Requirement
49
+ none: false
50
+ requirements:
51
+ - - ! '>='
52
+ - !ruby/object:Gem::Version
53
+ version: '0'
54
+ required_rubygems_version: !ruby/object:Gem::Requirement
55
+ none: false
56
+ requirements:
57
+ - - ! '>='
58
+ - !ruby/object:Gem::Version
59
+ version: '0'
60
+ requirements: []
61
+ rubyforge_project:
62
+ rubygems_version: 1.8.11
63
+ signing_key:
64
+ specification_version: 3
65
+ summary: OpenSSL RSA PKCS8 Extension
66
+ test_files: []