from_message (OpenID::Server::CheckAuthRequest)

    # File lib/openid/server.rb, line 81
          def self.from_message(message, op_endpoint=UNUSED)
            assoc_handle = message.get_arg(OPENID_NS, 'assoc_handle')
            invalidate_handle = message.get_arg(OPENID_NS, 'invalidate_handle')

            signed = message.copy()
            # openid.mode is currently check_authentication because
            # that's the mode of this request.  But the signature
            # was made on something with a different openid.mode.
            # http://article.gmane.org/gmane.comp.web.openid.general/537
            if signed.has_key?(OPENID_NS, "mode")
              signed.set_arg(OPENID_NS, "mode", "id_res")
            end

            obj = self.new(assoc_handle, signed, invalidate_handle)
            obj.message = message
            obj.namespace = message.get_openid_namespace()
            obj.sig = message.get_arg(OPENID_NS, 'sig')

            if !obj.assoc_handle or
                !obj.sig
              msg = sprintf("%s request missing required parameter from message %s",
                            obj.mode, message)
                raise ProtocolError.new(message, msg)
            end

            return obj
          end