Flags if the used Control impl detected a threat

@param DataInterface $data The incoming data to investigate

@return bool
330717
public function isThreat(DataInterface $data)
    {
        $response = $this->client->post(
            self::API_ENDPOINT,
            [
                'secret' => $this->secret,
                'response' => $data->getValue(),
            ]
        );

        if (!$response->isSuccess()) {
            return true;
        }

        $validation = json_decode($response->getBody());

        if (is_null($validation) || !$validation->success) {
            return true;
        }

        return false;
    }
115381
public function isValid(array $data)
    {
        if ($this->isCli) {
            return true;
        }

        return isset($data[self::TOKEN_KEY]) && $data[self::TOKEN_KEY] == $this->getToken();
    }
1331881
public function validate(ValidationData $data)
    {
        foreach ($this->getValidatableClaims() as $claim) {
            if (!$claim->validate($data)) {
                return false;
            }
        }

        return true;
    }
273585
private function checkExistenceWithCommand(CommandInterface $command)
    {
        try {
            $this->execute($command);
            return true;
        } catch (S3Exception $e) {
            if ($e->getAwsErrorCode() == 'AccessDenied') {
                return true;
            }
            if ($e->getStatusCode() >= 500) {
                throw $e;
            }
            return false;
        }
    }
216367
public function match($data)
    {
        if (!($data instanceof ModuleInterface)) {
            return false;
        }

        $files = $data->getFiles();

        return !empty($files);
    }
1343893
public function inboundText( $data=null ){
		if(!$data) $data = $_GET;

		if(!isset($data['text'], $data['msisdn'], $data['to'])) return false;

		// Get the relevant data
		$this->to = $data['to'];
		$this->from = $data['msisdn'];
		$this->text = $data['text'];
		$this->network = (isset($data['network-code'])) ? $data['network-code'] : '';
		$this->message_id = $data['messageId'];

		// Flag that we have an inbound message
		$this->inbound_message = true;

		return true;
	}
967400
protected function isSent($data = null)
  {
    if (!is_null($data)) {
      return true;
    }

    if ($name = $this->getName()) {
      return (bool)$this->getRequest()->get($name);
    }

    foreach ($this->fields as $n => $f) {
      if ($this->checkRequestHasValue($n)) {
        return true;
      }
    }

    return false;
  }
1166868
public function execute(DataSetInterface $dataSet)
    {
        $companyUnitAddressLabelEntity = SpyCompanyUnitAddressLabelQuery::create()
            ->filterByName($dataSet[CompanyUnitAddressLabelDataSet::LABEL_NAME])
            ->findOneOrCreate();

        $companyUnitAddressLabelEntity->save();
    }
1208989
private function validate($data)
    {
        // null or zero-length values cannot be assigned references
        if (is_null($data) || (is_string($data) && !strlen($data))) {
            return false;
        }

        return true;
    }
830241
protected function isEdgeInterruptCase(FlowInterface $flow)
    {
        return !$this->flowTarget ||
            (
                // asked to stop right here
                $this->flowTarget === InterrupterInterface::TARGET_SELF ||
                $this->flowTarget === $flow->getId() ||
                (
                    // target root when this Flow is root already
                    $this->flowTarget === InterrupterInterface::TARGET_TOP &&
                    !$flow->hasParent()
                )
            );
    }
1133589
public function isAllowedDebugCall($data)
    {
        // Check if the class itself is blacklisted.
        foreach ($this->classBlacklist as $classname) {
            if (is_a($data, $classname) === true) {
                // No debug methods for you.
                return false;
            }
        }

        // Nothing found?
        return true;
    }
568008
public function validate($data, QuestionInterface $question, ScoreInterface $score)
    {
        $answersValid = array();

        foreach ($question->getAnswers() as $answer) {
            if ($answer->isValid()) {
                $answersValid[] = $answer->getId();
            }
        }

        $tooManyAnswers = array_diff($data, $answersValid);

        if (!empty($tooManyAnswers)) {
            $score->addNotValid();

            return false;
        }

        $answerCompare = array_diff($answersValid, $data);

        if (empty($answersValid) && !empty($data)) {
            $score->addNotValid();

            return false;
        }

        if (count($answerCompare) === 0) {
            $score->addValid();
        } else if (count($answersValid) === count($answerCompare)) {
            $score->addNotValid();

            return false;
        } else if (count($answersValid) > count($answerCompare)) {
            $score->addPartial();

            return false;
        }

        return true;
    }
773476
public function has(VariableWrapper $data)
    {
        foreach ($this->metadatas as $metadata) {
            if ($metadata->supports($data)) {
                return true;
            }
        }

        return false;
    }
1024510
protected function hasConditionAndConditionNotMatched(CommandInterface $command): bool
    {
        if (!$this->isConditionalCommand($command) || $this->conditionMatched($command)) {
            return false;
        }

        return true;
    }
828675
public function execute($data) {

        try {
            foreach ($data as $row) {
                $config = $this->sanitizeConfig($row);
                if (! $this->doUpdates($config))
                    throw new \Exception('impossible to conciliate.');
            }
            return true;
        } catch (\Exception $exception) {
            throw $exception;
        }
    }
660101
public function isBlacklisted(AddressInterface $ip = null)
    {
        if ($ip === null) {
            $ip = $this->getRequestIPAddress();
        }
        $rangeType = $this->getRangeType($ip);

        return $rangeType !== null && ($rangeType & static::IPRANGEFLAG_BLACKLIST) === static::IPRANGEFLAG_BLACKLIST;
    }
1326518
protected function isValidConditionData($data)
    {
        if (!array_key_exists('field', $data)) {
            throw new MissingConditionAttributeException('field');
        }
        if (!array_key_exists('operator', $data)) {
            throw new MissingConditionAttributeException('operator');
        }
        if (!array_key_exists('type', $data)) {
            throw new MissingConditionAttributeException('type');
        }
        if (!array_key_exists('value', $data)) {
            throw new MissingConditionAttributeException('value');
        }

        return true;
    }