Call to check and verify your API key. You may then call the
 <tt>verified?</tt> method to see if your key has been validated
324154
def verify_api_key
      return :false if invalid_options?
      value = http_post(
        Net::HTTP.new(self.class.host, self.class.port, options[:proxy_host], options[:proxy_port]),
        'verify-key',
        {
          :key  => self.options[:api_key],
          :blog => self.options[:blog]
        }.to_query
      )
      self.verified_key = (value == 'valid') ? true : :false
    end
42798
def check_api_response(self, response):
        
        # check response
        if response.status_code == 200:
            return True
        elif response.status_code >= 400:
            logging.error(
                "{}: {} - {} - URL: {}".format(
                    response.status_code,
                    response.reason,
                    response.json().get("error"),
                    response.request.url,
                )
            )
            return False, response.status_code
262915
def verify_param(self, param, must=[], r=None):
        ''''''
        if APIKEY not in param:
            param[APIKEY] = self.apikey()

        r = Result() if r is None else r
        for p in must:
            if p not in param:
                r.code(Code.ARGUMENT_MISSING).detail('missing-' + p)
                break

        return r
205317
def Verify(self):
        
        if not self.Hash.ToBytes() == GetGenesis().Hash.ToBytes():
            return False

        bc = GetBlockchain()

        if not bc.ContainsBlock(self.Index):
            return False

        if self.Index > 0:
            prev_header = GetBlockchain().GetHeader(self.PrevHash.ToBytes())

            if prev_header is None:
                return False

            if prev_header.Index + 1 != self.Index:
                return False

            if prev_header.Timestamp >= self.Timestamp:
                return False

        # this should be done to actually verify the block
        if not Helper.VerifyScripts(self):
            return False

        return True
240800
@Override
    public void verify() throws SniffyAssertionError {
        checkOpened();
        SniffyAssertionError assertionError = getSniffyAssertionError();
        if (null != assertionError) {
            throw assertionError;
        }
    }
264508
function verify(req, identifier, profile, done) {
    var validOpEndpoint = 'https://steamcommunity.com/openid/login';
    var identifierRegex = /^https?:\/\/steamcommunity\.com\/openid\/id\/(\d+)$/;

    if(req.query['openid.op_endpoint'] !== validOpEndpoint ||
       !identifierRegex.test(identifier)) {
      return done(null, false, { message: 'Claimed identity is invalid.' });
    }

    var steamID = identifierRegex.exec(identifier)[0];

    if(options.profile) {
      getUserProfile(options.apiKey, steamID, function(err, profile) {
        if(err) {
          done(err);
        } else {
          if(originalPassReqToCallback) {
            validate(req, identifier, profile, done);
          } else {
            validate(identifier, profile, done);
          }
        }
      });
    } else {
      if(originalPassReqToCallback) {
        validate(req, identifier, profile, done);
      } else {
        validate(identifier, profile, done);
      }
    }
  }
797285
public boolean hasValidKey(HttpRequestHeader reqHeader, JSONObject params) {
		try {
			String apiPath;
			try {
				apiPath = reqHeader.getURI().getPath();
			} catch (URIException e) {
				logger.error(e.getMessage(), e);
				return false;
			}
			String nonceParam = reqHeader.getHeader(HttpHeader.X_ZAP_API_NONCE);
			if (nonceParam == null && params.has(API_NONCE_PARAM)) {
				nonceParam = params.getString(API_NONCE_PARAM);
			}
			
			if (nonceParam != null) {
				Nonce nonce = nonces.get(nonceParam);
				if (nonce == null) {
					logger.warn("API nonce " + nonceParam + " not found in request from " + reqHeader.getSenderAddress().getHostAddress());
					return false;
				} else if (nonce.isOneTime()) {
					nonces.remove(nonceParam);
				}
				if (! nonce.isValid()) {
					logger.warn("API nonce " + nonce.getNonceKey() + " expired at " + nonce.getExpires().toString() +
							" in request from " + reqHeader.getSenderAddress().getHostAddress());
					return false;
				}
				
				if (! apiPath.equals(nonce.getApiPath())) {
					logger.warn("API nonce path was " + nonce.getApiPath() + " but call was for " + apiPath + 
						" in request from " + reqHeader.getSenderAddress().getHostAddress());
					return false;
				}
			} else {
				String keyParam = reqHeader.getHeader(HttpHeader.X_ZAP_API_KEY);
				if (keyParam == null && params.has(API_KEY_PARAM)) {
					keyParam = params.getString(API_KEY_PARAM);
				}
				if (!getOptionsParamApi().getKey().equals(keyParam)) {
					logger.warn("API key incorrect or not supplied: " + keyParam +
							" in request from " + reqHeader.getSenderAddress().getHostAddress());
					return false;
				}
			}
			
			return true;
		} finally {
			synchronized (nonces) {
				for (Entry<String, Nonce> entry : nonces.entrySet()) {
					if (! entry.getValue().isValid()) {
						nonces.remove(entry.getKey());
					}
				}
			}
		}
	}
204714
public function isKeyValid()
    {
        // Check to see if the key is valid
        $response = $this->sendRequest('key=' . $this->wordPressAPIKey . '&blog=' . $this->blogURL, $this->akismetServer, '/' . $this->akismetVersion . '/verify-key');
        return $response[1] == 'valid';
    }
1248008
def verify(verified_entity, verification_key):
        
        verification = get_object_or_none(Verification, verified_entity=verified_entity)

        if verification is None:
            raise ServerError(VerificationHandler.STATUS_VERIFICATION_NOT_FOUND)
        if not verification.verify(verification_key):
            raise ServerError(VerificationHandler.STATUS_INVALID_VERIFICATION_KEY)

        verification.verified = True
        verification.save()
352980
def validate_key(self, key):
        
        if not key:
            name = self.__class__.__name__
            msg = "%s response missing %s" % (name, self.key_name)
            raise ValidationException(msg, self)
        elif not isinstance(key, str):
            msg = "Response contains invalid %s type" % self.key_name
            raise ValidationException(msg, type(key))
992795
def has_method(self, key: str) -> bool:
        
        return hasattr(self.__class__, key) and callable(getattr(self.__class__, key))
562140
public void verify(PublicKey key, Provider sigProvider)
            throws CertificateException, NoSuchAlgorithmException, InvalidKeyException, SignatureException {
        unwrap().verify(key, sigProvider);
    }
716177
def verifySignature(self, signatureKey):
        
        try:
            parts = ByteUtil.split(self.serialized,
                                   len(self.serialized) - self.__class__.SIGNATURE_LENGTH,
                                   self.__class__.SIGNATURE_LENGTH)

            if not Curve.verifySignature(signatureKey, parts[0], parts[1]):
                raise InvalidMessageException("Invalid signature!")
        except InvalidKeyException as e:
            raise InvalidMessageException(e)
233035
def verify(self):
        
        try:
            if self.timestamp_mismatch is not None:
                m = _iso8601_timestamp_regex.match(self.request_timestamp)
                year = int(m.group("year"))
                month = int(m.group("month"))
                day = int(m.group("day"))
                hour = int(m.group("hour"))
                minute = int(m.group("minute"))
                second = int(m.group("second"))

                req_ts = datetime(year, month, day, hour, minute, second)
                now = datetime.utcnow()

                if abs(req_ts - now) > timedelta(0, self.timestamp_mismatch):
                    raise InvalidSignatureError("Timestamp mismatch")

            if self.expected_signature != self.request_signature:
                raise InvalidSignatureError(
                    "Signature mismatch: expected %r, got %r" % (
                        self.expected_signature, self.request_signature))
        except (AttributeError, KeyError, ValueError) as e:
            raise InvalidSignatureError(str(e))

        return True
1068224
public void checkInvalidParameters() {
    	for(String key: map.keySet()) {
    		boolean wasRequested = requestedKeys != null && requestedKeys.contains(key);
    		if(!wasRequested) throw new IllegalArgumentException("Unknown parameter " + key);
    		
    	}
    }
449293
def is_ready(self, key):
        """"""
        if self.pending_callbacks is None or key not in self.pending_callbacks:
            raise UnknownKeyError("key %r is not pending" % (key,))
        return key in self.results
1278646
public boolean hasValidKey(HttpMessage msg) {
		try {
			HttpRequestHeader requestHeader = msg.getRequestHeader();
			return this.hasValidKey(requestHeader, getParams(requestHeader));
		} catch (ApiException e) {
			logger.error(e.getMessage(), e);
			return false;
		}
	}