oauth 0.6.1 → 0.6.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 414ee66cdf6d7d20e2caddba76264dc3a5d5d058157abe8cd77907cfe42e2fbe
4
- data.tar.gz: de2152db1bf49cb9397bb95eaf10ebbe67f755f3de478cb36e4350beda3b2b5f
3
+ metadata.gz: 41420311334e3c3f5bf3c7c0523c10dae50d84ff4788e87c28765a72665a169a
4
+ data.tar.gz: 58f1558f5d6c31c42405772c3ead07bfcc51754ceeff7c6b000f72b868833359
5
5
  SHA512:
6
- metadata.gz: 2ab63e0e09c842637f45bf7053eae8c834238b36cee7ae8771a70766c51cea0a1b1277c025a46caa9fb5499fd93ff342749dc42e70bb5a3351a169b894602f0d
7
- data.tar.gz: aca6573f60c0926534fa3f6b1e40695c3ddb96ee9153cc9a3bc3bf6948d831918c1f358afde4273eca4a9608b2e20cc75e8b86a2e9cc53ab257d1084a6130e0a
6
+ metadata.gz: 478782009426a1dab385f9ea8702fed19b7795b3116a5a49b9e9a527374e1fa1b62657f4413aeac7e439f7f2f339e2623d6e2bd9dcf42daefbce43caa4078144
7
+ data.tar.gz: 96195f350fba5187766484f3606016cd245f8cc26c9b1e7083ec11e00b4589cf57ee07d5c8a8097dd56e41c8476a3eaf52ecaa9bf67b5ad333e7a48a268e2992
data/CHANGELOG.md CHANGED
@@ -13,6 +13,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
13
13
 
14
14
  ### Removed
15
15
 
16
+ ## [0.6.2] 2022-08-29
17
+ ### Changed
18
+ * `OAuth::Comsumer#options` hash is now handled by `snaky_hash`, which was extracted from `oauth2`
19
+ * symbolized keys, dot-access and snake-case are now normalized
20
+
16
21
  ## [0.6.1] 2022-08-23
17
22
  ### Changed
18
23
  * Fixed documentation in SECURITY.md
@@ -35,6 +40,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
35
40
  ### Removed
36
41
  * Ruby 2.0, 2.1, 2.2, and 2.3 are no longer valid install targets
37
42
 
43
+ ## [0.5.14] 2022-08-29
44
+ The "hopeful last 0.5.x" Release
45
+
46
+ ### Fixed
47
+ * More typos fixed
48
+
38
49
  ## [0.5.13] 2022-08-23
39
50
  The "I think I caught 'em all!" Release
40
51
 
@@ -431,9 +442,11 @@ but please have a look at the unit tests.
431
442
  * Moved all non-Rails functionality from the Rails plugin:
432
443
  http://code.google.com/p/oauth-plugin/
433
444
 
434
- [Unreleased]: https://github.com/oauth-xx/oauth-ruby/compare/v0.6.1...v0.6-maintenance
445
+ [Unreleased]: https://github.com/oauth-xx/oauth-ruby/compare/v0.6.2...v0.6-maintenance
446
+ [0.6.2]: https://github.com/oauth-xx/oauth-ruby/releases/tag/v0.6.2
435
447
  [0.6.1]: https://github.com/oauth-xx/oauth-ruby/releases/tag/v0.6.1
436
448
  [0.6.0]: https://github.com/oauth-xx/oauth-ruby/releases/tag/v0.6.0
449
+ [0.5.14]: https://github.com/oauth-xx/oauth-ruby/releases/tag/v0.5.14
437
450
  [0.5.13]: https://github.com/oauth-xx/oauth-ruby/releases/tag/v0.5.13
438
451
  [0.5.12]: https://github.com/oauth-xx/oauth-ruby/releases/tag/v0.5.12
439
452
  [0.5.11]: https://github.com/oauth-xx/oauth-ruby/releases/tag/v0.5.11
data/README.md CHANGED
@@ -332,7 +332,7 @@ the [Pessimistic Version Constraint][pvc] with two digits of precision.
332
332
  For example:
333
333
 
334
334
  ```ruby
335
- spec.add_dependency "oauth", "~> 0.6.0"
335
+ spec.add_dependency "oauth", "~> 0.6.2"
336
336
  ```
337
337
 
338
338
  ## License
@@ -30,47 +30,49 @@ module OAuth
30
30
  end
31
31
  CA_FILE = nil unless defined?(CA_FILE)
32
32
 
33
- @@default_options = {
34
- # Signature method used by server. Defaults to HMAC-SHA1
35
- signature_method: "HMAC-SHA1",
36
-
37
- # default paths on site. These are the same as the defaults set up by the generators
38
- request_token_path: "/oauth/request_token",
39
- authenticate_path: "/oauth/authenticate",
40
- authorize_path: "/oauth/authorize",
41
- access_token_path: "/oauth/access_token",
42
-
43
- proxy: nil,
44
- # How do we send the oauth values to the server see
45
- # https://oauth.net/core/1.0/#consumer_req_param for more info
46
- #
47
- # Possible values:
48
- #
49
- # :header - via the Authorize header (Default) ( option 1. in spec)
50
- # :body - url form encoded in body of POST request ( option 2. in spec)
51
- # :query_string - via the query part of the url ( option 3. in spec)
52
- scheme: :header,
53
-
54
- # Default http method used for OAuth Token Requests (defaults to :post)
55
- http_method: :post,
56
-
57
- # Add a custom ca_file for consumer
58
- # :ca_file => '/etc/certs.pem'
59
-
60
- # Possible values:
61
- #
62
- # nil, false - no debug output
63
- # true - uses $stdout
64
- # some_value - uses some_value
65
- debug_output: nil,
66
-
67
- # Defaults to producing a body_hash as part of the signature but
68
- # can be disabled since it's not officially part of the OAuth 1.0
69
- # spec. Possible values are true and false
70
- body_hash_enabled: true,
71
-
72
- oauth_version: "1.0"
73
- }
33
+ @@default_options = SnakyHash::SymbolKeyed.new(
34
+ {
35
+ # Signature method used by server. Defaults to HMAC-SHA1
36
+ signature_method: "HMAC-SHA1",
37
+
38
+ # default paths on site. These are the same as the defaults set up by the generators
39
+ request_token_path: "/oauth/request_token",
40
+ authenticate_path: "/oauth/authenticate",
41
+ authorize_path: "/oauth/authorize",
42
+ access_token_path: "/oauth/access_token",
43
+
44
+ proxy: nil,
45
+ # How do we send the oauth values to the server see
46
+ # https://oauth.net/core/1.0/#consumer_req_param for more info
47
+ #
48
+ # Possible values:
49
+ #
50
+ # :header - via the Authorize header (Default) ( option 1. in spec)
51
+ # :body - url form encoded in body of POST request ( option 2. in spec)
52
+ # :query_string - via the query part of the url ( option 3. in spec)
53
+ scheme: :header,
54
+
55
+ # Default http method used for OAuth Token Requests (defaults to :post)
56
+ http_method: :post,
57
+
58
+ # Add a custom ca_file for consumer
59
+ # :ca_file => '/etc/certs.pem'
60
+
61
+ # Possible values:
62
+ #
63
+ # nil, false - no debug output
64
+ # true - uses $stdout
65
+ # some_value - uses some_value
66
+ debug_output: nil,
67
+
68
+ # Defaults to producing a body_hash as part of the signature but
69
+ # can be disabled since it's not officially part of the OAuth 1.0
70
+ # spec. Possible values are true and false
71
+ body_hash_enabled: true,
72
+
73
+ oauth_version: "1.0"
74
+ }
75
+ )
74
76
 
75
77
  attr_accessor :options, :key, :secret
76
78
  attr_writer :site, :http
@@ -103,7 +105,8 @@ module OAuth
103
105
  @secret = consumer_secret
104
106
 
105
107
  # ensure that keys are symbols
106
- @options = @@default_options.merge(options.transform_keys(&:to_sym))
108
+ snaky_options = SnakyHash::SymbolKeyed.new(options)
109
+ @options = @@default_options.merge(snaky_options)
107
110
  end
108
111
 
109
112
  # The default http method
data/lib/oauth/version.rb CHANGED
@@ -2,6 +2,6 @@
2
2
 
3
3
  module OAuth
4
4
  module Version
5
- VERSION = "0.6.1"
5
+ VERSION = "0.6.2"
6
6
  end
7
7
  end
data/lib/oauth.rb CHANGED
@@ -1,6 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  # third party gems
4
+ require "snaky_hash"
4
5
  require "version_gem"
5
6
 
6
7
  require "oauth/version"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: oauth
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.1
4
+ version: 0.6.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pelle Braendgaard
@@ -16,8 +16,22 @@ authors:
16
16
  autorequire:
17
17
  bindir: bin
18
18
  cert_chain: []
19
- date: 2022-08-23 00:00:00.000000000 Z
19
+ date: 2022-08-29 00:00:00.000000000 Z
20
20
  dependencies:
21
+ - !ruby/object:Gem::Dependency
22
+ name: snaky_hash
23
+ requirement: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - "~>"
26
+ - !ruby/object:Gem::Version
27
+ version: '2.0'
28
+ type: :runtime
29
+ prerelease: false
30
+ version_requirements: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - "~>"
33
+ - !ruby/object:Gem::Version
34
+ version: '2.0'
21
35
  - !ruby/object:Gem::Dependency
22
36
  name: version_gem
23
37
  requirement: !ruby/object:Gem::Requirement
@@ -254,23 +268,23 @@ licenses:
254
268
  - MIT
255
269
  metadata:
256
270
  homepage_uri: https://github.com/oauth-xx/oauth-ruby
257
- source_code_uri: https://github.com/oauth-xx/oauth-ruby/tree/v0.6.1
258
- changelog_uri: https://github.com/oauth-xx/oauth-ruby/blob/v0.6.1/CHANGELOG.md
271
+ source_code_uri: https://github.com/oauth-xx/oauth-ruby/tree/v0.6.2
272
+ changelog_uri: https://github.com/oauth-xx/oauth-ruby/blob/v0.6.2/CHANGELOG.md
259
273
  bug_tracker_uri: https://github.com/oauth-xx/oauth-ruby/issues
260
- documentation_uri: https://www.rubydoc.info/gems/oauth/0.6.1
274
+ documentation_uri: https://www.rubydoc.info/gems/oauth/0.6.2
261
275
  wiki_uri: https://github.com/oauth-xx/oauth-ruby/wiki
262
276
  rubygems_mfa_required: 'true'
263
277
  post_install_message: |2
264
278
 
265
- You have installed oauth version 0.6.1, congratulations!
279
+ You have installed oauth version 0.6.2, congratulations!
266
280
 
267
- Non-commercial support for the 0.6.x series will end in April, 2024. Please upgrade to 1.0.x as soon as possible!
281
+ Non-commercial support for the 0.6.x series will end by April, 2024. Please upgrade to 1.0.x as soon as possible!
268
282
  The only breaking change will be dropped support for Ruby 2.4, 2.5, and 2.6.
269
283
 
270
284
  Please see:
271
- • https://github.com/oauth-xx/oauth/blob/main/SECURITY.md
285
+ • https://github.com/oauth-xx/oauth-ruby/blob/main/SECURITY.md
272
286
 
273
- Note also that I, and this project, am in the process of leaving Github.
287
+ Note also that I am, and this project is, in the process of leaving Github.
274
288
  I wrote about some of the reasons here:
275
289
  • https://dev.to/galtzo/im-leaving-github-50ba
276
290
 
@@ -300,7 +314,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
300
314
  - !ruby/object:Gem::Version
301
315
  version: '0'
302
316
  requirements: []
303
- rubygems_version: 3.3.20
317
+ rubygems_version: 3.3.21
304
318
  signing_key:
305
319
  specification_version: 4
306
320
  summary: OAuth Core Ruby implementation