# File lib/openid/consumer/idres.rb, line 428
      def discover_and_verify(to_match)
        Util.log("Performing discovery on #{to_match.claimed_id}")
        _, services = OpenID.discover(to_match.claimed_id)
        if services.length == 0
          # XXX: this might want to be something other than
          # ProtocolError. In Python, it's DiscoveryFailure
          raise ProtocolError, ("No OpenID information found at "\
                                "#{to_match.claimed_id}")
        end
        verify_discovered_services(services, to_match)
      end