    # File lib/action_controller/vendor/rack-1.0/rack/auth/openid.rb, line 204
          def call(env)
            env['rack.auth.openid'] = self
            env_session = env[@session_key]
            unless env_session and env_session.is_a?(Hash)
              raise NoSession, 'No compatible session'
            end
            # let us work in our own namespace...
            session = (env_session[:openid] ||= {})
            unless session and session.is_a?(Hash)
              raise NoSession, 'Incompatible openid session'
            end

            request = Rack::Request.new(env)
            consumer = ::OpenID::Consumer.new(session, @store)

            if mode = request.GET['openid.mode']
              if session.key?(:openid_param)
                finish(consumer, session, request)
              else
                bad_request
              end
            elsif request.GET[@openid_param]
              check(consumer, session, request)
            else
              unauthorized
            end
          end