saml2 3.1.9 → 3.1.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bc5aca6567638769f3012c6200885b6788be090f2e15e097cb12c9eb2cf3ff04
4
- data.tar.gz: 00735ed468a298141864827fafc9aeb797b54d315f66395f96ca266286a63a58
3
+ metadata.gz: 99a6296632edaf74d6fc282ef56d06e94dc71787e02b254b5e366902a487f22d
4
+ data.tar.gz: d7ec1d384f710d3276f51114c34a84079eba0051f41af6a5ce1704c595a0b354
5
5
  SHA512:
6
- metadata.gz: ea30163098967400b3c280ad6c97bcf270ac5ecbc5c3a1d4f4a60e5a05168720f170cb3ee3716a4645d5d623dde57e9bc4f9b4a1dfeb7450dfc96fe3b0e85124
7
- data.tar.gz: 50c9aa22ddb01492ffbe3d5a2b0b7e898a9809e75c46f72d90085ad72486743daceb9f2818f8ba87bdcae0058655299956dc6338a9a93d2fc3ac7aa284e81360
6
+ metadata.gz: 00d66610046dd795906a1ea082c2244c4fabb17f92304005d707f60333233a69c76e059bb312171c3f3ee44470818e32686e418693b059fecb1171d7f6fa7745
7
+ data.tar.gz: 9ad6721b14a6098c51fa475bd0fec92728e217beb30f7ff314a0abe0765c55d1b3d5343d6e9f661ffda811994f3dc4d45749d603fc23e6303dd92c883ae2bc68
@@ -3,8 +3,8 @@
3
3
  module SAML2
4
4
  class Attribute
5
5
  class X500 < Attribute
6
- GIVEN_NAME = "urn:oid:2.5.4.42"
7
- SN = SURNAME = "urn:oid:2.5.4.4"
6
+ GIVEN_NAME = "urn:oid:2.5.4.42"
7
+ SN = SURNAME = "urn:oid:2.5.4.4"
8
8
  # https://www.ietf.org/rfc/rfc2798.txt
9
9
  module InetOrgPerson
10
10
  DISPLAY_NAME = "urn:oid:2.16.840.1.113730.3.1.241"
@@ -131,8 +131,9 @@ module SAML2
131
131
  lookup_qname("xs:date", Namespaces::ALL) =>
132
132
  [Date, nil, ->(v) { Date.parse(v) if v }],
133
133
  lookup_qname("xs:dateTime", Namespaces::ALL) =>
134
- [Time, ->(v) { v.iso8601 }, ->(v) { Time.parse(v) if v }]
134
+ [Time, lambda(&:iso8601), ->(v) { Time.parse(v) if v }]
135
135
  }.freeze
136
+ private_constant :XS_TYPES
136
137
 
137
138
  def convert_to_xsi(value)
138
139
  xs_type = nil
@@ -27,7 +27,7 @@ module SAML2
27
27
  # A signature, if present, will be verified only if +public_key+ is
28
28
  # passed.
29
29
  #
30
- # @param url [String]
30
+ # @param url [String, URI]
31
31
  # The full URL to decode. Will check for both +SAMLRequest+ and
32
32
  # +SAMLResponse+ params.
33
33
  # @param public_key optional [Array<OpenSSL::PKey>, OpenSSL::PKey, Proc]
@@ -45,7 +45,7 @@ module SAML2
45
45
  # The same as a +Proc+ provided to +public_key+. Deprecated.
46
46
  def decode(url, public_key: nil, public_key_used: nil)
47
47
  uri = begin
48
- URI.parse(url)
48
+ url.is_a?(URI) ? url : URI.parse(url)
49
49
  rescue URI::InvalidURIError
50
50
  raise CorruptMessage
51
51
  end
@@ -9,6 +9,11 @@ module SAML2
9
9
  # @return [String, Array<String>]
10
10
  attr_accessor :class_ref
11
11
 
12
+ def initialize(class_ref = nil)
13
+ super()
14
+ @class_ref = class_ref
15
+ end
16
+
12
17
  # (see Base#from_xml)
13
18
  def from_xml(node)
14
19
  super
@@ -30,7 +30,7 @@ module SAML2
30
30
  protected
31
31
 
32
32
  def build(status_response)
33
- super(status_response)
33
+ super
34
34
 
35
35
  status_response.parent["InResponseTo"] = in_response_to if in_response_to
36
36
 
data/lib/saml2/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SAML2
4
- VERSION = "3.1.9"
4
+ VERSION = "3.1.10"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: saml2
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.9
4
+ version: 3.1.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cody Cutrer
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2025-02-06 00:00:00.000000000 Z
11
+ date: 2025-02-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -90,14 +90,14 @@ dependencies:
90
90
  requirements:
91
91
  - - "~>"
92
92
  - !ruby/object:Gem::Version
93
- version: '12.0'
93
+ version: '13.2'
94
94
  type: :development
95
95
  prerelease: false
96
96
  version_requirements: !ruby/object:Gem::Requirement
97
97
  requirements:
98
98
  - - "~>"
99
99
  - !ruby/object:Gem::Version
100
- version: '12.0'
100
+ version: '13.2'
101
101
  - !ruby/object:Gem::Dependency
102
102
  name: rspec
103
103
  requirement: !ruby/object:Gem::Requirement
@@ -146,14 +146,14 @@ dependencies:
146
146
  requirements:
147
147
  - - "~>"
148
148
  - !ruby/object:Gem::Version
149
- version: '2.20'
149
+ version: '3.5'
150
150
  type: :development
151
151
  prerelease: false
152
152
  version_requirements: !ruby/object:Gem::Requirement
153
153
  requirements:
154
154
  - - "~>"
155
155
  - !ruby/object:Gem::Version
156
- version: '2.20'
156
+ version: '3.5'
157
157
  description: |
158
158
  The saml2 library is yet another SAML library for Ruby, with
159
159
  an emphasis on _not_ re-implementing XML, especially XML Security,