Setting up Permanent Session Token in DF 2.0

I got this to work but now I am getting an error when trying to login:

“The MAC is invalid.”

And I have no idea what this means…

Have you reported the error?.

But my issue is even to get it to work and i need info and ideas on how to even make it work, please.

Thanks

In version 2.1.2, you can extend the life of the token in the file:

… \ Dreamfactory-2.1.2-1 \ apps \ dreamfactory \ htdocs \ bootstrap \ cache \ config.php

‘Jwt’ =>
array (
<…>
‘Ttl’ => 1440 /60/
<…>

Changes to other config files (.env) have no effect.

If making changes to your .env file has no effect it is because your config is cached. This can be remedied by php artisan config:clear in the installation directory, and a restart of your web server service (apache/nginx)

I am building Rest Api and using dreamfactory 2.2.0 version and made changes in df.php file by setting
’allow_forever_sessions’ => env(‘DF_ALLOW_FOREVER_SESSIONS’, true),

and also use “remember_me”:true in code for eg.
{
“id” : 5,
“email” : "Zxy@example.com",
“password” : “Zxy”,
“remember_me”:true

}

But, still facing token expiration problem. I want to make token life forever.

I’m also getting the same issue.

  1. Don’t edit df.php. Instead edit your .env file.
  2. After editing the file you need to clear the configuration cache.
    See: https://wiki.dreamfactory.com/DreamFactory/Tutorials/Forever_sessions

You can verify the changes are effective by doing an authenticated GET on system/environment