You are here

public function HttpblEvaluatorInterface::setIpLocalStatus in http:BL 8

Create and store new evaluated hosts to httpbl_host table.

(legacy name was "_httpbl_cache_set".)

While getIpLocalStatus() should already be handling the scrubbing of any duplicates, this function will still double-check for existing records before adding a new one for the same host. If any are found, it will skip adding another one, and instead log an error.

Parameters

string $ip: The host_ip to identify a new stored host.

integer $status: The evaluated status to be stored with the new host.

int $offset: Time added to \Drupal::time()->getRequestTime() to determine the expiry of the host.

Return value

|void

1 method overrides HttpblEvaluatorInterface::setIpLocalStatus()
HttpblEvaluator::setIpLocalStatus in src/HttpblEvaluator.php
Create and store new evaluated hosts to httpbl_host table.

File

src/HttpblEvaluatorInterface.php, line 102

Class

HttpblEvaluatorInterface
Provides an interface defining a HttpblEvaluate manager.

Namespace

Drupal\httpbl

Code

public function setIpLocalStatus($ip, $status, $offset = 0);