libsaml 2.19.6 → 2.19.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/saml/version.rb +1 -1
- data/lib/saml/xml_helpers.rb +18 -5
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fa6f0d8f142b82814c9a9a4c0669f9a32aa6e69b
|
4
|
+
data.tar.gz: 42a3649651b3626eaef94ec97dbfbe49e9a5fcb7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: be12ed8f23c115b23c6ad241d67d502636fc78352428c61f7bf77cb25d8bd2c9238f7e9c4a34ecd965b695b2eefb5ec121d89ba30436aa1105e603b81bb5e6a5
|
7
|
+
data.tar.gz: d4dd1ec3a61499e21f194aa2c007ece52496cace8547f1e21c3620cc4434c5e0cc3617af28b3dfc86a62213d6ce73f39b54973d7a4cdd5ae5144152c10d84997
|
data/lib/saml/version.rb
CHANGED
data/lib/saml/xml_helpers.rb
CHANGED
@@ -1,4 +1,3 @@
|
|
1
|
-
|
2
1
|
module Saml
|
3
2
|
module XMLHelpers
|
4
3
|
extend ActiveSupport::Concern
|
@@ -17,7 +16,7 @@ module Saml
|
|
17
16
|
write_xml = builder.nil? ? true : false
|
18
17
|
builder ||= Nokogiri::XML::Builder.new
|
19
18
|
builder.doc.encoding = "UTF-8"
|
20
|
-
result
|
19
|
+
result = if use_parsed? && respond_to?(:xml_value)
|
21
20
|
builder << xml_value
|
22
21
|
builder
|
23
22
|
else
|
@@ -37,9 +36,23 @@ module Saml
|
|
37
36
|
|
38
37
|
builder = Nokogiri::XML::Builder.new(:encoding => "UTF-8")
|
39
38
|
builder.Envelope(:'xmlns:soapenv' => "http://schemas.xmlsoap.org/soap/envelope/") do |xml|
|
40
|
-
|
41
|
-
|
42
|
-
|
39
|
+
xml.parent.namespace = xml.parent.namespace_definitions.find { |n| n.prefix == 'soapenv' }
|
40
|
+
|
41
|
+
if header_options = options[:header]
|
42
|
+
xml.Header do |xml|
|
43
|
+
xml.MessageID(header_options[:wsa_message_id].presence || "uuid:#{SecureRandom.uuid}")
|
44
|
+
xml.Action(header_options[:wsa_action])
|
45
|
+
xml.To(header_options[:wsa_to]) if options[:wsa_to]
|
46
|
+
if header_options[:wsa_address]
|
47
|
+
xml.ReplyTo do |xml|
|
48
|
+
xml.Address(header_options[:wsa_address])
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
53
|
+
|
54
|
+
xml.Body do |xml|
|
55
|
+
xml.parent.add_child body.doc.root
|
43
56
|
end
|
44
57
|
end
|
45
58
|
builder.to_xml(nokogiri_options(options))
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: libsaml
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.19.
|
4
|
+
version: 2.19.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Benoist Claassen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-12-
|
11
|
+
date: 2015-12-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -240,7 +240,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
240
240
|
version: '0'
|
241
241
|
requirements: []
|
242
242
|
rubyforge_project:
|
243
|
-
rubygems_version: 2.4.
|
243
|
+
rubygems_version: 2.4.5.1
|
244
244
|
signing_key:
|
245
245
|
specification_version: 4
|
246
246
|
summary: A gem to easily create SAML 2.0 messages.
|