summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorlolcat <will@lolcat.ca>2023-11-08 09:05:39 -0500
committerlolcat <will@lolcat.ca>2023-11-08 09:05:39 -0500
commit5236452f450cd1bf32558f60e3258d302b14957b (patch)
tree5408dd7af36ac12443597a851751f7a92f7333d2 /lib
parent89b952ff40592140f2b87b0a16bf029844f06f9a (diff)
apcu fix
Diffstat (limited to 'lib')
-rw-r--r--lib/backend.php7
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/backend.php b/lib/backend.php
index a1c90ab..c76a0be 100644
--- a/lib/backend.php
+++ b/lib/backend.php
@@ -11,7 +11,6 @@ class backend{
*/
public function get_ip(){
- $this->requestid = apcu_inc("real_requests");
$pool = constant("config::PROXY_" . strtoupper($this->scraper));
if($pool === false){
@@ -106,18 +105,18 @@ class backend{
$tag = "";
$out = openssl_encrypt($payload, "aes-256-gcm", $key, OPENSSL_RAW_DATA, $iv, $tag, "", 16);
- $key = apcu_inc("key", 1);
+ $requestid = apcu_inc("requestid");
apcu_store(
$page . "." .
$this->scraper .
- $this->requestid,
+ $requestid,
gzdeflate($proxy . "," . $salt.$iv.$out.$tag),
900 // cache information for 15 minutes blaze it
);
return
- $this->scraper . $this->requestid . "." .
+ $this->scraper . $requestid . "." .
rtrim(strtr(base64_encode($password), '+/', '-_'), '=');
}