spid-es 0.0.16 → 0.0.17

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,7 @@
1
1
  ---
2
- !binary "U0hBMQ==":
3
- metadata.gz: !binary |-
4
- ZmZkZDMyNGI0NTRkZmQ1OTQ0NWM5MTAyZWQ0ZGY4MDY4NWRhNmVhYw==
5
- data.tar.gz: !binary |-
6
- ODFiOTczNDYwZDIyYTQwNzA4NDEzY2M4NTY2Y2ZlNTU5MzVhYzMwOA==
2
+ SHA1:
3
+ metadata.gz: 46be801884c409dbaef8e4cf38f1b9e021450f26
4
+ data.tar.gz: a31cd522075c5b7f42871c5c9be69d24d4054d53
7
5
  SHA512:
8
- metadata.gz: !binary |-
9
- M2M0NWM0NjcwMGU1N2UyM2MxNzljMGRjNzZkNmMxOTM0YzM2NGM4NDM0Yzcy
10
- OWZkMTc3Zjk0NmRkOTY5NWM1MmRhMTlmZDdkNTk4ZmNlNGI0MTMxMGRlNmFj
11
- Yjk2NDcyY2NkMWExZDQ1YjYzZmUyYjE3NjA2ZWZkN2I5N2I4YmI=
12
- data.tar.gz: !binary |-
13
- ODgyZWIwYjQwY2NmZDQxYTBjNTRkM2ViYWRjYWU1MzY5ZTE3MWNiNGNiYjE4
14
- ODE5MjUyYjQ3OTM5MmQ4N2RlOWU1YTQ3OTFiM2ViYTZlMDE5NDYxNWQ4NWVj
15
- Njc4N2E4Y2U2MzNjOGUzOWVlODc4MmQwZjg0NTEyNWE4MDczY2I=
6
+ metadata.gz: b27913fae6a4da0b4dec6095c7c83e75c5aae44e59c706458cefd30f4ee96fa153f329d04e7d6d6de90807ec0a74c5c7bb41c9290f4e3364b665bde2b22c74c0
7
+ data.tar.gz: f9b403c288e4e5297a5220b526b1b858a03f5d45582225a4e8037378c19401e65ae1be1615cd758d8f3962d95f4a8ac1b13453a8554c7e223a2beb6181af4fd3
@@ -112,30 +112,83 @@ module Spid
112
112
  end
113
113
 
114
114
  if settings.assertion_consumer_service_url
115
- sp_sso.add_element "md:AssertionConsumerService", {
116
- "Binding" => settings.assertion_consumer_service_binding,
117
- "Location" => settings.assertion_consumer_service_url,
118
- "isDefault" => true,
119
- "index" => 0
120
- }
121
- end
115
+
116
+ #ciclo e creo i vari tag AssertionConsumerService
117
+ settings.requested_attribute.each_pair{ |index, hash_service|
118
+
119
+ sp_sso.add_element "md:AssertionConsumerService", {
120
+ "Binding" => settings.assertion_consumer_service_binding,
121
+ "Location" => (hash_service['external'] ? hash_service['url_consumer'] : settings.assertion_consumer_service_url ),
122
+ "isDefault" => hash_service['default'],
123
+ "index" => index
124
+ }
125
+ }
126
+
127
+ # #Caso con eidas
128
+ # sp_sso.add_element "md:AssertionConsumerService", {
129
+ # "Binding" => settings.assertion_consumer_service_binding,
130
+ # "Location" => settings.assertion_consumer_service_url,
131
+ # "index" => 99
132
+ # }
133
+
134
+ # sp_sso.add_element "md:AssertionConsumerService", {
135
+ # "Binding" => settings.assertion_consumer_service_binding,
136
+ # "Location" => settings.assertion_consumer_service_url,
137
+ # "index" => 100
138
+ # }
139
+
140
+ settings.requested_attribute.each_pair{ |index, hash_service|
141
+
142
+ #AttributeConsumingService
143
+ attr_cons_service = sp_sso.add_element "md:AttributeConsumingService", {
144
+ "index" => index,
145
+ }
146
+ service_name = attr_cons_service.add_element "md:ServiceName", {
147
+ "xml:lang" => "it"
148
+ }
149
+ service_name.text = hash_service['testo']
150
+ hash_service['array_campi'].each_with_index{ |attribute, index|
151
+ attr_cons_service.add_element "md:RequestedAttribute", {
152
+ "Name" => attribute
153
+ }
154
+ }
155
+ }
156
+
157
+
158
+
159
+
160
+ #Per EIDAS
161
+ # #AttributeConsumingService
162
+ # attr_cons_service = sp_sso.add_element "md:AttributeConsumingService", {
163
+ # "index" => "99",
164
+ # }
165
+ # service_name
166
+ # = attr_cons_service.add_element "md:ServiceName", {
167
+ # "xml:lang" => "it"
168
+ # }
169
+ # service_name.text = "eIDAS Natural Person Minimum Attribute Set"
170
+ # settings.requested_attribute.each_with_index{ |attribute, index|
171
+ # attr_cons_service.add_element "md:RequestedAttribute", {
172
+ # "Name" => attribute
173
+ # }
174
+ # }
175
+
176
+ # #AttributeConsumingService
177
+ # attr_cons_service = sp_sso.add_element "md:AttributeConsumingService", {
178
+ # "index" => "100",
179
+ # }
180
+ # service_name = attr_cons_service.add_element "md:ServiceName", {
181
+ # "xml:lang" => "it"
182
+ # }
183
+ # service_name.text = "eIDAS Natural Person Full Attribute Set"
184
+ # settings.requested_attribute.each_with_index{ |attribute, index|
185
+ # attr_cons_service.add_element "md:RequestedAttribute", {
186
+ # "Name" => attribute
187
+ # }
188
+ # }
122
189
 
123
-
124
190
 
125
- #AttributeConsumingService
126
- attr_cons_service = sp_sso.add_element "md:AttributeConsumingService", {
127
- "index" => "0",
128
- }
129
- service_name = attr_cons_service.add_element "md:ServiceName", {
130
- "xml:lang" => "it"
131
- }
132
- service_name.text = "User Data"
133
- settings.requested_attribute.each_with_index{ |attribute, index|
134
- attr_cons_service.add_element "md:RequestedAttribute", {
135
- "Name" => attribute
136
- }
137
- }
138
-
191
+ end
139
192
  #organization
140
193
  organization = root.add_element "md:Organization"
141
194
  org_name = organization.add_element "md:OrganizationName", {
@@ -4,9 +4,9 @@ module Spid
4
4
  module Saml
5
5
  class Settings
6
6
 
7
- attr_accessor :sp_name_qualifier, :sp_name_identifier, :sp_cert, :sp_private_key, :metadata_signed, :requested_attribute, :organization
7
+ attr_accessor :sp_name_qualifier, :sp_name_identifier, :sp_cert, :sp_private_key, :metadata_signed, :requested_attribute,:requested_attribute_eidas_min, :requested_attribute_eidas_full, :organization
8
8
  attr_accessor :idp_sso_target_url, :idp_cert_fingerprint, :idp_cert, :idp_slo_target_url, :idp_metadata, :idp_metadata_ttl, :idp_name_qualifier
9
- attr_accessor :assertion_consumer_service_binding, :assertion_consumer_service_url, :assertion_consumer_service_index, :attribute_consuming_service_index
9
+ attr_accessor :assertion_consumer_service_binding, :assertion_consumer_service_url, :assertion_consumer_service_index, :attribute_consuming_service_index, :hash_assertion_consumer
10
10
  attr_accessor :name_identifier_value, :name_identifier_format
11
11
  attr_accessor :sessionindex, :issuer, :destination_service_url, :authn_context, :requester_identificator
12
12
  attr_accessor :single_logout_service_url, :single_logout_service_binding, :single_logout_destination
data/spid-es.gemspec CHANGED
@@ -2,7 +2,7 @@ $LOAD_PATH.push File.expand_path('../lib', __FILE__)
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = 'spid-es'
5
- s.version = '0.0.16'
5
+ s.version = '0.0.17'
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["Fabiano Pavan"]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spid-es
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.16
4
+ version: 0.0.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Fabiano Pavan
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-10-26 00:00:00.000000000 Z
11
+ date: 2019-08-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: canonix
@@ -28,28 +28,28 @@ dependencies:
28
28
  name: uuid
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - ~>
31
+ - - "~>"
32
32
  - !ruby/object:Gem::Version
33
33
  version: '2.3'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - ~>
38
+ - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: '2.3'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: nokogiri
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - ! '>='
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: 1.6.7.2
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
54
  version: 1.6.7.2
55
55
  - !ruby/object:Gem::Dependency
@@ -66,14 +66,14 @@ dependencies:
66
66
  - - '='
67
67
  - !ruby/object:Gem::Version
68
68
  version: 2.4.0
69
- description: ! 'SAML toolkit for Ruby programs to integrate with SPID '
69
+ description: 'SAML toolkit for Ruby programs to integrate with SPID '
70
70
  email: fabiano.pavan@soluzionipa.it
71
71
  executables: []
72
72
  extensions: []
73
73
  extra_rdoc_files: []
74
74
  files:
75
- - .document
76
- - .travis.yml
75
+ - ".document"
76
+ - ".travis.yml"
77
77
  - Gemfile
78
78
  - LICENSE
79
79
  - README.md
@@ -127,22 +127,22 @@ licenses:
127
127
  metadata: {}
128
128
  post_install_message:
129
129
  rdoc_options:
130
- - --charset=UTF-8
130
+ - "--charset=UTF-8"
131
131
  require_paths:
132
132
  - lib
133
133
  required_ruby_version: !ruby/object:Gem::Requirement
134
134
  requirements:
135
- - - ! '>='
135
+ - - ">="
136
136
  - !ruby/object:Gem::Version
137
137
  version: '0'
138
138
  required_rubygems_version: !ruby/object:Gem::Requirement
139
139
  requirements:
140
- - - ! '>='
140
+ - - ">="
141
141
  - !ruby/object:Gem::Version
142
142
  version: '0'
143
143
  requirements: []
144
144
  rubyforge_project:
145
- rubygems_version: 2.4.3
145
+ rubygems_version: 2.2.2
146
146
  signing_key:
147
147
  specification_version: 4
148
148
  summary: SAML Ruby Tookit Spid