Jelajahi Sumber

setup a 15' expiration delay to captcha challenge

olinox14 1 tahun lalu
induk
melakukan
1072717278
1 mengubah file dengan 2 tambahan dan 1 penghapusan
  1. 2 1
      src/State/Provider/ChallengeProvider.php

+ 2 - 1
src/State/Provider/ChallengeProvider.php

@@ -29,7 +29,8 @@ class ChallengeProvider implements ProviderInterface
 
         $options = new ChallengeOptions([
             'hmacKey'   => $this->hmacKey,
-            'maxNumber' => 100000
+            'maxNumber' => 100000,
+            'expires' => (new \DateTime())->modify('+15 minute')
         ]);
 
         return Altcha::createChallenge($options);