Sha256: 7c66caea66c887623cca7449c2f5e84f9b337d96164c4fcdea71ad981081c59f
Contents?: true
Size: 922 Bytes
Versions: 30
Compression:
Stored size: 922 Bytes
Contents
module Rack module OAuth2 module Server class Resource class MAC < Resource def call(env) self.request = Request.new(env) super end private class Request < Resource::Request attr_reader :nonce, :body_hash, :ext, :signature def setup! auth_params = Rack::Auth::Digest::Params.parse(@auth_header.params).with_indifferent_access @access_token = auth_params[:id] @nonce = auth_params[:nonce] @body_hash = auth_params[:bodyhash] @ext = auth_params[:ext] @signature = auth_params[:mac] self end def oauth2? @auth_header.provided? && @auth_header.scheme == :mac end end end end end end end require 'rack/oauth2/server/resource/mac/error'
Version data entries
30 entries across 30 versions & 1 rubygems