Class: Rack::OAuth2::AccessToken::MAC::Sha256HexVerifier

Inherits:
Verifier
  • Object
show all
Defined in:
lib/rack/oauth2/access_token/mac/sha256_hex_verifier.rb

Instance Method Summary collapse

Methods inherited from Verifier

#initialize, #verify!

Constructor Details

This class inherits a constructor from Rack::OAuth2::AccessToken::MAC::Verifier

Instance Method Details

#calculateObject



8
9
10
11
12
# File 'lib/rack/oauth2/access_token/mac/sha256_hex_verifier.rb', line 8

def calculate
  return nil unless raw_body.present?
  
  OpenSSL::Digest::SHA256.new.digest(raw_body).unpack('H*').first
end