cerner-oauth1a 2.5.3 → 2.5.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/lib/cerner/oauth1a/access_token.rb +7 -7
- data/lib/cerner/oauth1a/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7c216d39c6c458e3987b9b46dbedf8cd58c462fd336d1042d1f7f827e0be71f3
|
4
|
+
data.tar.gz: 79166e522691bbac84d2190bad3f824441eb3b2c8448c6547c1874a627703f4e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 298d94d966ff6bed04ab29f8ee8ad3076507e9cc950517eff5bf0fb9c31d15b89924fa5c1fe384b1fd20f16688327b90267178b7bcf80b9958dcd6e0cb2d0b2d
|
7
|
+
data.tar.gz: d3e0c95062ed21513a20c47c2115f0385260173f60ed9c7676c320084b787c2488d301f7436330ebdae9f78d044790837c2694197e34ef70f2ba3d769bb61cad
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,8 @@
|
|
1
|
+
# v2.5.4
|
2
|
+
Replace invalid usage of `oauth_parameters_rejected` and `oauth_parameters_absent`
|
3
|
+
OAuth problem values with correct values `parameter_rejected` and `parameter_absent`
|
4
|
+
when reporting certain errors.
|
5
|
+
|
1
6
|
# v2.5.3
|
2
7
|
Use a constant time compare algorithm for checking a signature
|
3
8
|
|
@@ -368,7 +368,7 @@ module Cerner
|
|
368
368
|
# Internal: Used by #authenticate to verify the expiration time.
|
369
369
|
def verify_expiration(expires_on)
|
370
370
|
unless expires_on
|
371
|
-
raise OAuthError.new('token missing ExpiresOn', nil, '
|
371
|
+
raise OAuthError.new('token missing ExpiresOn', nil, 'parameter_rejected', 'oauth_token', @realm)
|
372
372
|
end
|
373
373
|
|
374
374
|
expires_on = Internal.convert_to_time(time: expires_on, name: 'expires_on')
|
@@ -380,7 +380,7 @@ module Cerner
|
|
380
380
|
# Internal: Used by #authenticate to load the keys
|
381
381
|
def load_keys(access_token_agent, keys_version)
|
382
382
|
unless keys_version
|
383
|
-
raise OAuthError.new('token missing KeysVersion', nil, '
|
383
|
+
raise OAuthError.new('token missing KeysVersion', nil, 'parameter_rejected', 'oauth_token', @realm)
|
384
384
|
end
|
385
385
|
|
386
386
|
begin
|
@@ -389,7 +389,7 @@ module Cerner
|
|
389
389
|
raise OAuthError.new(
|
390
390
|
'token references invalid keys version',
|
391
391
|
nil,
|
392
|
-
'
|
392
|
+
'parameter_rejected',
|
393
393
|
'oauth_token',
|
394
394
|
@realm
|
395
395
|
)
|
@@ -400,16 +400,16 @@ module Cerner
|
|
400
400
|
def verify_token(keys)
|
401
401
|
return if keys.verify_rsasha1_signature(@token)
|
402
402
|
|
403
|
-
raise OAuthError.new('token is not authentic', nil, '
|
403
|
+
raise OAuthError.new('token is not authentic', nil, 'parameter_rejected', 'oauth_token', @realm)
|
404
404
|
end
|
405
405
|
|
406
406
|
# Internal: Used by #authenticate to verify the request signature.
|
407
407
|
def verify_signature(keys:, hmac_secrets:, http_method:, fully_qualified_url:, request_params:)
|
408
408
|
unless @signature
|
409
|
-
raise OAuthError.new('missing signature', nil, '
|
409
|
+
raise OAuthError.new('missing signature', nil, 'parameter_absent', 'oauth_signature', @realm)
|
410
410
|
end
|
411
411
|
unless hmac_secrets
|
412
|
-
raise OAuthError.new('missing HMACSecrets', nil, '
|
412
|
+
raise OAuthError.new('missing HMACSecrets', nil, 'parameter_rejected', 'oauth_token', @realm)
|
413
413
|
end
|
414
414
|
|
415
415
|
begin
|
@@ -418,7 +418,7 @@ module Cerner
|
|
418
418
|
raise OAuthError.new(
|
419
419
|
"unable to decrypt HMACSecrets: #{e.message}",
|
420
420
|
nil,
|
421
|
-
'
|
421
|
+
'parameter_rejected',
|
422
422
|
'oauth_token',
|
423
423
|
@realm
|
424
424
|
)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cerner-oauth1a
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.5.
|
4
|
+
version: 2.5.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nathan Beyer
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-06-28 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: |
|
14
14
|
A minimal dependency library for interacting with a Cerner OAuth 1.0a Access
|