set default time of token to 365 days

This commit is contained in:
Uwe Steinmann 2023-02-08 20:46:01 +01:00
parent 6c65dbd6b0
commit 7fe0f08ba5

View File

@ -183,7 +183,7 @@ class SeedDMS_ExtPaperless_RestAPI_Controller { /* {{{ */
if(!empty($settings->_extensions['paperless']['tokenlivetime']))
$days = (int) $settings->_extensions['paperless']['tokenlivetime'];
else
$days = 1000;
$days = 365;
if(!$tokenstr = $token->jwtEncode($userobj->getId().':'.(time()+$days*84600))) {
return $response->withStatus(403);
}