xmlenc 0.6.8 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.travis.yml +7 -8
- data/CHANGELOG.md +5 -0
- data/README.md +4 -1
- data/Rakefile +18 -2
- data/lib/xmlenc.rb +1 -0
- data/lib/xmlenc/algorithms/aes_cbc.rb +1 -1
- data/lib/xmlenc/algorithms/aes_gcm.rb +59 -0
- data/lib/xmlenc/algorithms/des3_cbc.rb +1 -1
- data/lib/xmlenc/builder/base.rb +1 -1
- data/lib/xmlenc/builder/encrypted_data.rb +18 -1
- data/lib/xmlenc/encrypted_data.rb +4 -1
- data/lib/xmlenc/version.rb +1 -1
- data/spec/lib/xmlenc/algorithms/aes_gcm_spec.rb +65 -0
- data/spec/lib/xmlenc/builder/base_spec.rb +1 -1
- data/spec/lib/xmlenc/builder/encrypted_data_spec.rb +24 -8
- data/spec/lib/xmlenc/encrypted_document_spec.rb +0 -6
- data/spec/lib/xmlenc/phaos_compat_spec.rb +5 -5
- data/xmlenc.gemspec +17 -25
- metadata +17 -14
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 189069caca22405d127c3d7814b26a34203962b33537d39684d7bcf54bec40cd
|
4
|
+
data.tar.gz: b3d3b202f281123001ded9d4a01e210fdfa4d70408a693e73d1d6017f7164df2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e0e2f5fed7fe6be20f00b009d8346f76dddfdf72ed042adc328bd0b5dfbd81b77651eecc82e4201086b18f0c5c96db73df75855bac4ed7ddc2aeb8345bea90c2
|
7
|
+
data.tar.gz: 533f7b9c88eba4686ea805b7aadfa1f2a02a745e0dd1926e9d6e5459f8163bacb6ed5b3ae56f1372bbb041ecc00b21bc74a4807403abeddf42e23f64ef91ed7d
|
data/.travis.yml
CHANGED
data/CHANGELOG.md
ADDED
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
[![Build Status](https://travis-ci.
|
1
|
+
[![Build Status](https://app.travis-ci.com/digidentity/xmlenc.svg?branch=master)](https://app.travis-ci.com/digidentity/xmlenc)
|
2
2
|
[![Coverage Status](https://coveralls.io/repos/digidentity/xmlenc/badge.svg?branch=master&service=github)](https://coveralls.io/github/digidentity/xmlenc?branch=master)
|
3
3
|
[![Code Climate](https://codeclimate.com/github/digidentity/xmlenc/badges/gpa.svg)](https://codeclimate.com/github/digidentity/xmlenc)
|
4
4
|
|
@@ -39,6 +39,9 @@ Data algorithms
|
|
39
39
|
* http://www.w3.org/2001/04/xmlenc#tripledes-cbc
|
40
40
|
* http://www.w3.org/2001/04/xmlenc#aes128-cbc
|
41
41
|
* http://www.w3.org/2001/04/xmlenc#aes256-cbc
|
42
|
+
* http://www.w3.org/2009/xmlenc11#aes128-gcm
|
43
|
+
* http://www.w3.org/2009/xmlenc11#aes192-gcm
|
44
|
+
* http://www.w3.org/2009/xmlenc11#aes256-gcm
|
42
45
|
|
43
46
|
Key algorithms
|
44
47
|
|
data/Rakefile
CHANGED
@@ -4,6 +4,24 @@ begin
|
|
4
4
|
rescue LoadError
|
5
5
|
puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
|
6
6
|
end
|
7
|
+
begin
|
8
|
+
require 'rdoc/task'
|
9
|
+
rescue LoadError
|
10
|
+
require 'rdoc/rdoc'
|
11
|
+
require 'rake/rdoctask'
|
12
|
+
RDoc::Task = Rake::RDocTask
|
13
|
+
end
|
14
|
+
|
15
|
+
RDoc::Task.new(:rdoc) do |rdoc|
|
16
|
+
rdoc.rdoc_dir = 'rdoc'
|
17
|
+
rdoc.title = 'Saml'
|
18
|
+
rdoc.options << '--line-numbers'
|
19
|
+
rdoc.rdoc_files.include('README.rdoc')
|
20
|
+
rdoc.rdoc_files.include('lib/**/*.rb')
|
21
|
+
end
|
22
|
+
|
23
|
+
require "bundler/gem_tasks"
|
24
|
+
require "rake/testtask"
|
7
25
|
|
8
26
|
require "rspec/core/rake_task"
|
9
27
|
|
@@ -12,5 +30,3 @@ RSpec::Core::RakeTask.new(:core) do |spec|
|
|
12
30
|
end
|
13
31
|
|
14
32
|
task :default => [:core]
|
15
|
-
|
16
|
-
Bundler::GemHelper.install_tasks
|
data/lib/xmlenc.rb
CHANGED
@@ -38,6 +38,7 @@ module Xmlenc
|
|
38
38
|
autoload :RsaOaepMgf1p, 'xmlenc/algorithms/rsa_oaep_mgf1p'
|
39
39
|
autoload :DES3CBC, 'xmlenc/algorithms/des3_cbc'
|
40
40
|
autoload :AESCBC, 'xmlenc/algorithms/aes_cbc'
|
41
|
+
autoload :AESGCM, 'xmlenc/algorithms/aes_gcm'
|
41
42
|
end
|
42
43
|
|
43
44
|
autoload :EncryptedDocument, 'xmlenc/encrypted_document'
|
@@ -0,0 +1,59 @@
|
|
1
|
+
module Xmlenc
|
2
|
+
module Algorithms
|
3
|
+
class AESGCM
|
4
|
+
AUTH_TAG_LEN = 16
|
5
|
+
|
6
|
+
class << self
|
7
|
+
def [](size)
|
8
|
+
new(size)
|
9
|
+
end
|
10
|
+
end
|
11
|
+
|
12
|
+
def initialize(size)
|
13
|
+
@size = size
|
14
|
+
end
|
15
|
+
|
16
|
+
def setup(key = nil)
|
17
|
+
@cipher= nil
|
18
|
+
@iv = nil
|
19
|
+
@key = key || cipher.random_key
|
20
|
+
self
|
21
|
+
end
|
22
|
+
|
23
|
+
def decrypt(cipher_value, options = {})
|
24
|
+
cipher.decrypt
|
25
|
+
cipher.padding = 0
|
26
|
+
cipher.key = @key
|
27
|
+
cipher.iv = cipher_value[0...iv_len]
|
28
|
+
cipher.auth_tag = cipher_value[-AUTH_TAG_LEN..-1]
|
29
|
+
cipher.update(cipher_value[iv_len..-(AUTH_TAG_LEN + 1)]) << cipher.final
|
30
|
+
end
|
31
|
+
|
32
|
+
def encrypt(data, options = {})
|
33
|
+
cipher.encrypt
|
34
|
+
cipher.key = @key
|
35
|
+
cipher.iv = iv
|
36
|
+
cipher.auth_data = ''
|
37
|
+
iv << (cipher.update(data) << cipher.final) << cipher.auth_tag
|
38
|
+
end
|
39
|
+
|
40
|
+
def key
|
41
|
+
@key
|
42
|
+
end
|
43
|
+
|
44
|
+
private
|
45
|
+
|
46
|
+
def iv
|
47
|
+
@iv ||= cipher.random_iv
|
48
|
+
end
|
49
|
+
|
50
|
+
def iv_len
|
51
|
+
cipher.iv_len
|
52
|
+
end
|
53
|
+
|
54
|
+
def cipher
|
55
|
+
@cipher ||= OpenSSL::Cipher.new("aes-#{@size}-gcm")
|
56
|
+
end
|
57
|
+
end
|
58
|
+
end
|
59
|
+
end
|
data/lib/xmlenc/builder/base.rb
CHANGED
@@ -31,7 +31,7 @@ module Xmlenc
|
|
31
31
|
|
32
32
|
module XmlMapperClassMethods
|
33
33
|
def parse(xml, options = {})
|
34
|
-
raise Xmlenc::UnparseableMessage("Unable to parse nil document") if xml.nil?
|
34
|
+
raise Xmlenc::UnparseableMessage.new("Unable to parse nil document") if xml.nil?
|
35
35
|
|
36
36
|
object = super
|
37
37
|
if object.is_a?(Array)
|
@@ -6,7 +6,10 @@ module Xmlenc
|
|
6
6
|
ALGORITHMS = {
|
7
7
|
'http://www.w3.org/2001/04/xmlenc#tripledes-cbc' => Algorithms::DES3CBC,
|
8
8
|
'http://www.w3.org/2001/04/xmlenc#aes128-cbc' => Algorithms::AESCBC[128],
|
9
|
-
'http://www.w3.org/2001/04/xmlenc#aes256-cbc' => Algorithms::AESCBC[256]
|
9
|
+
'http://www.w3.org/2001/04/xmlenc#aes256-cbc' => Algorithms::AESCBC[256],
|
10
|
+
'http://www.w3.org/2009/xmlenc11#aes128-gcm' => Algorithms::AESGCM[128],
|
11
|
+
'http://www.w3.org/2009/xmlenc11#aes192-gcm' => Algorithms::AESGCM[192],
|
12
|
+
'http://www.w3.org/2009/xmlenc11#aes256-gcm' => Algorithms::AESGCM[256]
|
10
13
|
}
|
11
14
|
TYPES = {
|
12
15
|
'http://www.w3.org/2001/04/xmlenc#Element' => :element,
|
@@ -37,9 +40,16 @@ module Xmlenc
|
|
37
40
|
encryptor = algorithm.setup
|
38
41
|
encrypted = encryptor.encrypt(data, :node => encryption_method)
|
39
42
|
cipher_data.cipher_value = Base64.encode64(encrypted)
|
43
|
+
|
40
44
|
key_params = { :data => encryptor.key }
|
45
|
+
|
41
46
|
encrypted_key = EncryptedKey.new(key_params.merge(key_options))
|
42
47
|
encrypted_key.add_data_reference(id)
|
48
|
+
|
49
|
+
if key_options[:carried_key_name].present?
|
50
|
+
encrypted_key.carried_key_name = key_options[:carried_key_name]
|
51
|
+
end
|
52
|
+
|
43
53
|
encrypted_key
|
44
54
|
end
|
45
55
|
|
@@ -50,6 +60,13 @@ module Xmlenc
|
|
50
60
|
end
|
51
61
|
end
|
52
62
|
|
63
|
+
def set_key_name(key_name)
|
64
|
+
if key_name
|
65
|
+
self.key_info ||= KeyInfo.new
|
66
|
+
self.key_info.key_name = key_name
|
67
|
+
end
|
68
|
+
end
|
69
|
+
|
53
70
|
private
|
54
71
|
|
55
72
|
def algorithm
|
@@ -3,7 +3,10 @@ module Xmlenc
|
|
3
3
|
ALGORITHMS = {
|
4
4
|
'http://www.w3.org/2001/04/xmlenc#tripledes-cbc' => Algorithms::DES3CBC,
|
5
5
|
'http://www.w3.org/2001/04/xmlenc#aes128-cbc' => Algorithms::AESCBC[128],
|
6
|
-
'http://www.w3.org/2001/04/xmlenc#aes256-cbc' => Algorithms::AESCBC[256]
|
6
|
+
'http://www.w3.org/2001/04/xmlenc#aes256-cbc' => Algorithms::AESCBC[256],
|
7
|
+
'http://www.w3.org/2009/xmlenc11#aes128-gcm' => Algorithms::AESGCM[128],
|
8
|
+
'http://www.w3.org/2009/xmlenc11#aes192-gcm' => Algorithms::AESGCM[192],
|
9
|
+
'http://www.w3.org/2009/xmlenc11#aes256-gcm' => Algorithms::AESGCM[256]
|
7
10
|
}
|
8
11
|
|
9
12
|
TYPES = {
|
data/lib/xmlenc/version.rb
CHANGED
@@ -0,0 +1,65 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe Xmlenc::Algorithms::AESGCM do
|
4
|
+
let(:data) { "<CreditCard Currency=\"USD\" Limit=\"5,000\">\r\n <Number>4019 2445 0277 5567</Number>\r\n <Issuer>Bank of the Internet</Issuer>\r\n <Expiration Time=\"04/02\"/>\r\n </CreditCard>" }
|
5
|
+
|
6
|
+
describe 'aes128-gcm' do
|
7
|
+
let(:cipher_value) { Base64.decode64 "YjIkLPqklVVN1faEgndPFXgXaOlVVaL+5X8NCDkbgQsbv6D2Jo7d9NQCyMbp1MgU2myCUynzdXMKdVIaqTt14pkr+NtYD6kBFPUkTvbcMIc86L5aqoMIEeqeJCK3aYLNGcY05xxOpuHvMzh2tEoZPFLEd9WgsNGhfv+4GqKiXxMVrjeLp7Iz9dYB4XmfLnQr62m4vYsZpxzg0mkxX6miCDNplv4wVBSwMDCvAFbAoWltKd+upjwaPQDNLIp0GYfQdCr7cu6K0ep4sIc=" }
|
8
|
+
let(:key) { %w(1e8c108fc0521dcad99ff2daad45af64).pack('H*') }
|
9
|
+
let(:iv) { %w(6232242cfaa495554dd5f684).pack('H*') }
|
10
|
+
subject { described_class.new(128).setup(key) }
|
11
|
+
|
12
|
+
describe 'encrypt' do
|
13
|
+
it 'encrypts the data' do
|
14
|
+
allow(subject).to receive(:iv).and_return(iv)
|
15
|
+
expect(subject.encrypt(data)).to be == cipher_value
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
describe 'decrypt' do
|
20
|
+
it 'decrypts the cipher_value' do
|
21
|
+
expect(subject.decrypt(cipher_value)).to be == data
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
25
|
+
|
26
|
+
describe 'aes192-gcm' do
|
27
|
+
let(:cipher_value) { Base64.decode64 "YjIkLPqklVVN1faETdI41CyJetO9+vdpho9swtvre7VRd5GpkFxp3lioUUlL2URCVx24YMHOzI6ksj0jQxASXn5uvNdIUrOxtTUzzUlIKk2Jbsi6uecP/YNz7NINxz4RqcjxiH+X8IF9etWAjRt+Z2zI/5YaUsQ/kPcrfesUxaH+6aMH9XWDXNqHdCjlxxMTw/4Sj9GqGmdC73CdokggeS8dfF05TZRF4lH2kTZ/RBgS7EEwwXZVKlq6yHfe5Jv2VxHqKJ8f/OSEyiw=" }
|
28
|
+
let(:key) { %w(68432eb84dcb27e6cf46cc8d2cb1659484bbea7d0a8131f4).pack('H*') }
|
29
|
+
let(:iv) { %w(6232242cfaa495554dd5f684).pack('H*') }
|
30
|
+
subject { described_class.new(192).setup(key) }
|
31
|
+
|
32
|
+
describe 'encrypt' do
|
33
|
+
it 'encrypts the data' do
|
34
|
+
allow(subject).to receive(:iv).and_return(iv)
|
35
|
+
expect(subject.encrypt(data)).to be == cipher_value
|
36
|
+
end
|
37
|
+
end
|
38
|
+
|
39
|
+
describe 'decrypt' do
|
40
|
+
it 'decrypts the cipher_value' do
|
41
|
+
expect(subject.decrypt(cipher_value)).to be == data
|
42
|
+
end
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
describe 'aes256-gcm' do
|
47
|
+
let(:cipher_value) { Base64.decode64 "YjIkLPqklVVN1faEcqScF7ALyB/fb+q3+HRW17n2rUqvdO8AmI4h7wXOwj5wgeP7KBCuR6IWQK9bUeZE+EoIR+tQNXmN8CofZ6s81QbZEPMiNdRnurXz0LNaSZUL1D1ivic62TYtfgqVX+z7wesGBviRM+vHcfRQlmN5sSzBtgPF9n5u2D6mpG9fa/+I33pAFDy2FeHI1CFPzLzbvKDqnjfM7zDd0YbsNi+5czoWl7likHNplPXR1jhLxOmKPWloKQVEG8f2KHsL/ZI=" }
|
48
|
+
let(:key) { %w(7b655b83e4821c9302d24be876b7783b2301b06b4ff89cabe8e9809d7602f207).pack('H*') }
|
49
|
+
let(:iv) { %w(6232242cfaa495554dd5f684).pack('H*') }
|
50
|
+
subject { described_class.new(256).setup(key) }
|
51
|
+
|
52
|
+
describe 'encrypt' do
|
53
|
+
it 'encrypts the data' do
|
54
|
+
allow(subject).to receive(:iv).and_return(iv)
|
55
|
+
expect(subject.encrypt(data)).to be == cipher_value
|
56
|
+
end
|
57
|
+
end
|
58
|
+
|
59
|
+
describe 'decrypt' do
|
60
|
+
it 'decrypts the cipher_value' do
|
61
|
+
expect(subject.decrypt(cipher_value)).to be == data
|
62
|
+
end
|
63
|
+
end
|
64
|
+
end
|
65
|
+
end
|
@@ -112,23 +112,39 @@ describe Xmlenc::Builder::EncryptedData do
|
|
112
112
|
expect(Xmlenc::Builder::EncryptedKey).to receive(:new).with(hash_including(key_options))
|
113
113
|
subject.encrypt('TEST', key_options)
|
114
114
|
end
|
115
|
+
|
116
|
+
context 'when a "carried_key_name" is passed' do
|
117
|
+
let(:key_options) { { :id => '_SOME_ID', :recipient => 'SOME_RECIPIENT', :carried_key_name => 'CARRIED_KEY_NAME' } }
|
118
|
+
|
119
|
+
it 'sets the carried key name' do
|
120
|
+
expect(subject.encrypt('TEST', key_options).carried_key_name).to eq 'CARRIED_KEY_NAME'
|
121
|
+
end
|
122
|
+
end
|
115
123
|
end
|
116
124
|
end
|
117
125
|
|
118
|
-
describe
|
119
|
-
it
|
126
|
+
describe '#set_key_retrieval_method' do
|
127
|
+
it 'sets the key info with the retrieval method' do
|
120
128
|
subject.set_key_retrieval_method 'retrieval_method'
|
121
|
-
expect(subject.key_info.retrieval_method).to eq
|
129
|
+
expect(subject.key_info.retrieval_method).to eq 'retrieval_method'
|
130
|
+
end
|
131
|
+
|
132
|
+
it 'does not set the key info element if the "retrieval_method" is nil' do
|
133
|
+
subject.key_info = nil
|
134
|
+
subject.set_key_retrieval_method(nil)
|
135
|
+
expect(subject.key_info).to be_nil
|
122
136
|
end
|
137
|
+
end
|
123
138
|
|
124
|
-
|
125
|
-
|
126
|
-
|
139
|
+
describe '#set_key_name' do
|
140
|
+
it 'sets the key info with the key name' do
|
141
|
+
subject.set_key_name 'key_name'
|
142
|
+
expect(subject.key_info.key_name).to eq 'key_name'
|
127
143
|
end
|
128
144
|
|
129
|
-
it
|
145
|
+
it 'does not set the key info element if the "key_name" is nil' do
|
130
146
|
subject.key_info = nil
|
131
|
-
subject.
|
147
|
+
subject.set_key_name(nil)
|
132
148
|
expect(subject.key_info).to be_nil
|
133
149
|
end
|
134
150
|
end
|
@@ -65,10 +65,4 @@ describe Xmlenc::EncryptedDocument do
|
|
65
65
|
end
|
66
66
|
end
|
67
67
|
|
68
|
-
describe 'parsing documents' do
|
69
|
-
let(:encrypted_xml) { File.read('spec/fixtures/artifact_response.xml') }
|
70
|
-
fit 'finds the correct data' do
|
71
|
-
puts subject.encrypted_keys.count
|
72
|
-
end
|
73
|
-
end
|
74
68
|
end
|
@@ -14,7 +14,7 @@ describe 'Phaos compatibility tests' do
|
|
14
14
|
|
15
15
|
key = private_key.private_decrypt(key_cipher, OpenSSL::PKey::RSA::PKCS1_OAEP_PADDING)
|
16
16
|
|
17
|
-
cipher = OpenSSL::Cipher
|
17
|
+
cipher = OpenSSL::Cipher.new('des-ede3-cbc')
|
18
18
|
cipher.decrypt
|
19
19
|
cipher.key = key
|
20
20
|
cipher.iv = data_cipher[0...cipher.iv_len]
|
@@ -35,7 +35,7 @@ describe 'Phaos compatibility tests' do
|
|
35
35
|
|
36
36
|
key = private_key.private_decrypt(key_cipher, OpenSSL::PKey::RSA::PKCS1_OAEP_PADDING)
|
37
37
|
|
38
|
-
cipher = OpenSSL::Cipher
|
38
|
+
cipher = OpenSSL::Cipher.new('aes-128-cbc')
|
39
39
|
cipher.decrypt
|
40
40
|
cipher.key = key
|
41
41
|
cipher.iv = data_cipher[0...cipher.iv_len]
|
@@ -56,7 +56,7 @@ describe 'Phaos compatibility tests' do
|
|
56
56
|
|
57
57
|
key = private_key.private_decrypt(key_cipher)
|
58
58
|
|
59
|
-
cipher = OpenSSL::Cipher
|
59
|
+
cipher = OpenSSL::Cipher.new('aes-128-cbc')
|
60
60
|
cipher.decrypt
|
61
61
|
cipher.key = key
|
62
62
|
cipher.iv = data_cipher[0...cipher.iv_len]
|
@@ -77,7 +77,7 @@ describe 'Phaos compatibility tests' do
|
|
77
77
|
|
78
78
|
key = private_key.private_decrypt(key_cipher)
|
79
79
|
|
80
|
-
cipher = OpenSSL::Cipher
|
80
|
+
cipher = OpenSSL::Cipher.new('aes-256-cbc')
|
81
81
|
cipher.decrypt
|
82
82
|
cipher.key = key
|
83
83
|
cipher.iv = data_cipher[0...cipher.iv_len]
|
@@ -98,7 +98,7 @@ describe 'Phaos compatibility tests' do
|
|
98
98
|
|
99
99
|
key = private_key.private_decrypt(key_cipher, OpenSSL::PKey::RSA::PKCS1_OAEP_PADDING)
|
100
100
|
|
101
|
-
cipher = OpenSSL::Cipher
|
101
|
+
cipher = OpenSSL::Cipher.new('aes-256-cbc')
|
102
102
|
cipher.decrypt
|
103
103
|
cipher.key = key
|
104
104
|
cipher.iv = data_cipher[0...cipher.iv_len]
|
data/xmlenc.gemspec
CHANGED
@@ -1,36 +1,28 @@
|
|
1
|
-
|
2
|
-
lib = File.expand_path('../lib', __FILE__)
|
3
|
-
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
1
|
+
$:.push File.expand_path('../lib', __FILE__)
|
4
2
|
require 'xmlenc/version'
|
5
3
|
|
6
4
|
Gem::Specification.new do |spec|
|
7
|
-
spec.name =
|
5
|
+
spec.name = 'xmlenc'
|
8
6
|
spec.version = Xmlenc::VERSION
|
9
|
-
spec.authors = [
|
10
|
-
spec.email = [
|
11
|
-
spec.description =
|
12
|
-
spec.summary =
|
13
|
-
spec.homepage =
|
14
|
-
spec.license =
|
7
|
+
spec.authors = ['Benoist']
|
8
|
+
spec.email = ['bclaassen@digidentity.eu']
|
9
|
+
spec.description = 'A (partial)implementation of the XMLENC specificiation'
|
10
|
+
spec.summary = 'A (partial)implementation of the XMLENC specificiation'
|
11
|
+
spec.homepage = 'https://github.com/digidentity/xmlenc'
|
12
|
+
spec.license = 'MIT'
|
15
13
|
|
16
14
|
spec.files = `git ls-files`.split($/)
|
17
15
|
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
18
16
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
19
|
-
spec.require_paths = [
|
17
|
+
spec.require_paths = ['lib']
|
20
18
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
else
|
26
|
-
spec.add_dependency "activesupport", ">= 3.0.0"
|
27
|
-
spec.add_dependency "activemodel", ">= 3.0.0"
|
28
|
-
spec.add_dependency "xmlmapper", '~> 0.6'
|
29
|
-
spec.add_runtime_dependency('nokogiri', '>= 1.6.0', '< 2.0.0')
|
30
|
-
end
|
19
|
+
spec.add_runtime_dependency 'activesupport', '>= 3.0.0'
|
20
|
+
spec.add_runtime_dependency 'activemodel', '>= 3.0.0'
|
21
|
+
spec.add_runtime_dependency 'xmlmapper', '>= 0.7.3'
|
22
|
+
spec.add_runtime_dependency 'nokogiri', '>= 1.6.0', '< 2.0.0'
|
31
23
|
|
32
|
-
spec.add_development_dependency
|
33
|
-
spec.add_development_dependency
|
34
|
-
spec.add_development_dependency
|
35
|
-
spec.add_development_dependency
|
24
|
+
spec.add_development_dependency 'bundler'
|
25
|
+
spec.add_development_dependency 'rspec-rails', '>= 2.14'
|
26
|
+
spec.add_development_dependency 'rake'
|
27
|
+
spec.add_development_dependency 'coveralls'
|
36
28
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xmlenc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Benoist
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-08-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -42,16 +42,16 @@ dependencies:
|
|
42
42
|
name: xmlmapper
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - "
|
45
|
+
- - ">="
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version:
|
47
|
+
version: 0.7.3
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- - "
|
52
|
+
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
54
|
+
version: 0.7.3
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: nokogiri
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
@@ -76,28 +76,28 @@ dependencies:
|
|
76
76
|
name: bundler
|
77
77
|
requirement: !ruby/object:Gem::Requirement
|
78
78
|
requirements:
|
79
|
-
- - "
|
79
|
+
- - ">="
|
80
80
|
- !ruby/object:Gem::Version
|
81
|
-
version: '
|
81
|
+
version: '0'
|
82
82
|
type: :development
|
83
83
|
prerelease: false
|
84
84
|
version_requirements: !ruby/object:Gem::Requirement
|
85
85
|
requirements:
|
86
|
-
- - "
|
86
|
+
- - ">="
|
87
87
|
- !ruby/object:Gem::Version
|
88
|
-
version: '
|
88
|
+
version: '0'
|
89
89
|
- !ruby/object:Gem::Dependency
|
90
90
|
name: rspec-rails
|
91
91
|
requirement: !ruby/object:Gem::Requirement
|
92
92
|
requirements:
|
93
|
-
- - "
|
93
|
+
- - ">="
|
94
94
|
- !ruby/object:Gem::Version
|
95
95
|
version: '2.14'
|
96
96
|
type: :development
|
97
97
|
prerelease: false
|
98
98
|
version_requirements: !ruby/object:Gem::Requirement
|
99
99
|
requirements:
|
100
|
-
- - "
|
100
|
+
- - ">="
|
101
101
|
- !ruby/object:Gem::Version
|
102
102
|
version: '2.14'
|
103
103
|
- !ruby/object:Gem::Dependency
|
@@ -138,12 +138,14 @@ files:
|
|
138
138
|
- ".gitignore"
|
139
139
|
- ".rspec"
|
140
140
|
- ".travis.yml"
|
141
|
+
- CHANGELOG.md
|
141
142
|
- Gemfile
|
142
143
|
- LICENSE.txt
|
143
144
|
- README.md
|
144
145
|
- Rakefile
|
145
146
|
- lib/xmlenc.rb
|
146
147
|
- lib/xmlenc/algorithms/aes_cbc.rb
|
148
|
+
- lib/xmlenc/algorithms/aes_gcm.rb
|
147
149
|
- lib/xmlenc/algorithms/des3_cbc.rb
|
148
150
|
- lib/xmlenc/algorithms/rsa_15.rb
|
149
151
|
- lib/xmlenc/algorithms/rsa_oaep_mgf1p.rb
|
@@ -181,6 +183,7 @@ files:
|
|
181
183
|
- spec/fixtures/template.xml
|
182
184
|
- spec/fixtures/template2.xml
|
183
185
|
- spec/lib/xmlenc/algorithms/aes_cbc_spec.rb
|
186
|
+
- spec/lib/xmlenc/algorithms/aes_gcm_spec.rb
|
184
187
|
- spec/lib/xmlenc/algorithms/des3_cbc_spec.rb
|
185
188
|
- spec/lib/xmlenc/algorithms/rsa_15_spec.rb
|
186
189
|
- spec/lib/xmlenc/algorithms/rsa_oaep_mgf1p_spec.rb
|
@@ -222,8 +225,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
222
225
|
- !ruby/object:Gem::Version
|
223
226
|
version: '0'
|
224
227
|
requirements: []
|
225
|
-
|
226
|
-
rubygems_version: 2.5.1
|
228
|
+
rubygems_version: 3.1.4
|
227
229
|
signing_key:
|
228
230
|
specification_version: 4
|
229
231
|
summary: A (partial)implementation of the XMLENC specificiation
|
@@ -247,6 +249,7 @@ test_files:
|
|
247
249
|
- spec/fixtures/template.xml
|
248
250
|
- spec/fixtures/template2.xml
|
249
251
|
- spec/lib/xmlenc/algorithms/aes_cbc_spec.rb
|
252
|
+
- spec/lib/xmlenc/algorithms/aes_gcm_spec.rb
|
250
253
|
- spec/lib/xmlenc/algorithms/des3_cbc_spec.rb
|
251
254
|
- spec/lib/xmlenc/algorithms/rsa_15_spec.rb
|
252
255
|
- spec/lib/xmlenc/algorithms/rsa_oaep_mgf1p_spec.rb
|