I installed 2FA Two-Factor Login Security, but the user's 2FA add-on cannot be enabled and an exception occurs.

Permalink Browser Info Environment
I installed 2FA Two-Factor Login Security, but the user's 2FA add-on cannot be enabled and an exception occurs.
I don't know the cause, so could you tell me how to deal with it?

Operation details
You are an individual user by user search, and if you add "2FA Two-Factor Login Security" in addition to the attribute and execute it, it terminates abnormally.


log
Fatal error: Uncaught Whoops\Exception\ErrorException: Undefined variable $ga_activate_tsa in C:\XXXXXX\MAMP\htdocs\concrete5\packages\two_step_authentication\attributes\two_step_auth_data\composer.php:26 Stack trace: #0 C:\XXXXXX\MAMP\htdocs\concrete5\packages\two_step_authentication\attributes\two_step_auth_data\composer.php(26): Whoops\Run->handleError(2, 'Undefined varia...', 'C:\\XXXXXX\\MAMP...', 26) #1 C:\XXXXXX\MAMP\htdocs\concrete5\concrete\src\View\AbstractView.php(180): include('C:\\XXXXXX\\MAMP...') #2 C:\XXXXXX\MAMP\htdocs\concrete5\concrete\src\View\AbstractView.php(164): Concrete\Core\View\AbstractView->renderViewContents(Array) #3 C:\XXXXXX\MAMP\htdocs\concrete5\concrete\src\Attribute\Key\Component\KeySelector\KeySerializer.php(82): Concrete\Core\View\AbstractView->render(Object(Concrete\Core\Attribute\Context\AttributePanelContext)) #4 [internal function]: Concrete\Core\Attribute\Key\Component\KeySelector\KeySerializer->jsonSerialize() #5 C:\XXXXXX\MAMP\htdocs\concrete5\concrete\src\Error\Handler\JsonErrorHandler.php(79): json_encode(Array) #6 C:\XXXXXX\MAMP\htdocs\concrete5\concrete\vendor\filp\whoops\src\Whoops\Run.php(370): Concrete\Core\Error\Handler\JsonErrorHandler->handle(Object(Whoops\Exception\ErrorException)) #7 [internal function]: Whoops\Run->handleException(Object(Whoops\Exception\ErrorException)) #8 {main} thrown in C:\XXXXXX\MAMP\htdocs\concrete5\packages\two_step_authentication\attributes\two_step_auth_data\composer.php on line 26
{"error":{"type":"Whoops\\Exception\\ErrorException","message":"Uncaught Whoops\\Exception\\ErrorException: Undefined variable $ga_activate_tsa in C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\packages\\two_step_authentication\\attributes\\two_step_auth_data\\composer.php:26\nStack trace:\n#0 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\packages\\two_step_authentication\\attributes\\two_step_auth_data\\composer.php(26): Whoops\\Run->handleError(2, 'Undefined varia...', 'C:\\\\XXXXXX\\\\MAMP...', 26)\n#1 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\View\\AbstractView.php(180): include('C:\\\\XXXXXX\\\\MAMP...')\n#2 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\View\\AbstractView.php(164): Concrete\\Core\\View\\AbstractView->renderViewContents(Array)\n#3 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\Attribute\\Key\\Component\\KeySelector\\KeySerializer.php(82): Concrete\\Core\\View\\AbstractView->render(Object(Concrete\\Core\\Attribute\\Context\\AttributePanelContext))\n#4 [internal function]: Concrete\\Core\\Attribute\\Key\\Component\\KeySelector\\KeySerializer->jsonSerialize()\n#5 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\Error\\Handler\\JsonErrorHandler.php(79): json_encode(Array)\n#6 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\vendor\\filp\\whoops\\src\\Whoops\\Run.php(370): Concrete\\Core\\Error\\Handler\\JsonErrorHandler->handle(Object(Whoops\\Exception\\ErrorException))\n#7 [internal function]: Whoops\\Run->handleException(Object(Whoops\\Exception\\ErrorException))\n#8 {main}\n thrown","code":1,"file":"C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\packages\\two_step_authentication\\attributes\\two_step_auth_data\\composer.php","line":26,"trace":[{"file":"C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\packages\\two_step_authentication\\attributes\\two_step_auth_data\\composer.php","line":26,"function":null,"class":"Whoops\\Exception\\ErrorException","args":["Uncaught Whoops\\Exception\\ErrorException: Undefined variable $ga_activate_tsa in C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\packages\\two_step_authentication\\attributes\\two_step_auth_data\\composer.php:26\nStack trace:\n#0 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\packages\\two_step_authentication\\attributes\\two_step_auth_data\\composer.php(26): Whoops\\Run->handleError(2, 'Undefined varia...', 'C:\\\\XXXXXX\\\\MAMP...', 26)\n#1 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\View\\AbstractView.php(180): include('C:\\\\XXXXXX\\\\MAMP...')\n#2 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\View\\AbstractView.php(164): Concrete\\Core\\View\\AbstractView->renderViewContents(Array)\n#3 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\Attribute\\Key\\Component\\KeySelector\\KeySerializer.php(82): Concrete\\Core\\View\\AbstractView->render(Object(Concrete\\Core\\Attribute\\Context\\AttributePanelContext))\n#4 [internal function]: Concrete\\Core\\Attribute\\Key\\Component\\KeySelector\\KeySerializer->jsonSerialize()\n#5 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\Error\\Handler\\JsonErrorHandler.php(79): json_encode(Array)\n#6 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\vendor\\filp\\whoops\\src\\Whoops\\Run.php(370): Concrete\\Core\\Error\\Handler\\JsonErrorHandler->handle(Object(Whoops\\Exception\\ErrorException))\n#7 [internal function]: Whoops\\Run->handleException(Object(Whoops\\Exception\\ErrorException))\n#8 {main}\n thrown"]},{"file":"C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\vendor\\filp\\whoops\\src\\Whoops\\Run.php","line":486,"function":"handleError","class":"Whoops\\Run","args":[1,"Uncaught Whoops\\Exception\\ErrorException: Undefined variable $ga_activate_tsa in C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\packages\\two_step_authentication\\attributes\\two_step_auth_data\\composer.php:26\nStack trace:\n#0 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\packages\\two_step_authentication\\attributes\\two_step_auth_data\\composer.php(26): Whoops\\Run->handleError(2, 'Undefined varia...', 'C:\\\\XXXXXX\\\\MAMP...', 26)\n#1 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\View\\AbstractView.php(180): include('C:\\\\XXXXXX\\\\MAMP...')\n#2 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\View\\AbstractView.php(164): Concrete\\Core\\View\\AbstractView->renderViewContents(Array)\n#3 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\Attribute\\Key\\Component\\KeySelector\\KeySerializer.php(82): Concrete\\Core\\View\\AbstractView->render(Object(Concrete\\Core\\Attribute\\Context\\AttributePanelContext))\n#4 [internal function]: Concrete\\Core\\Attribute\\Key\\Component\\KeySelector\\KeySerializer->jsonSerialize()\n#5 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\Error\\Handler\\JsonErrorHandler.php(79): json_encode(Array)\n#6 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\vendor\\filp\\whoops\\src\\Whoops\\Run.php(370): Concrete\\Core\\Error\\Handler\\JsonErrorHandler->handle(Object(Whoops\\Exception\\ErrorException))\n#7 [internal function]: Whoops\\Run->handleException(Object(Whoops\\Exception\\ErrorException))\n#8 {main}\n thrown","C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\packages\\two_step_authentication\\attributes\\two_step_auth_data\\composer.php",26]},{"file":"[internal]","line":0,"function":"handleShutdown","class":"Whoops\\Run","args":[]}]},"errors":["Uncaught Whoops\\Exception\\ErrorException: Undefined variable $ga_activate_tsa in C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\packages\\two_step_authentication\\attributes\\two_step_auth_data\\composer.php:26\nStack trace:\n#0 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\packages\\two_step_authentication\\attributes\\two_step_auth_data\\composer.php(26): Whoops\\Run->handleError(2, 'Undefined varia...', 'C:\\\\XXXXXX\\\\MAMP...', 26)\n#1 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\View\\AbstractView.php(180): include('C:\\\\XXXXXX\\\\MAMP...')\n#2 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\View\\AbstractView.php(164): Concrete\\Core\\View\\AbstractView->renderViewContents(Array)\n#3 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\Attribute\\Key\\Component\\KeySelector\\KeySerializer.php(82): Concrete\\Core\\View\\AbstractView->render(Object(Concrete\\Core\\Attribute\\Context\\AttributePanelContext))\n#4 [internal function]: Concrete\\Core\\Attribute\\Key\\Component\\KeySelector\\KeySerializer->jsonSerialize()\n#5 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\src\\Error\\Handler\\JsonErrorHandler.php(79): json_encode(Array)\n#6 C:\\XXXXXX\\MAMP\\htdocs\\concrete5\\concrete\\vendor\\filp\\whoops\\src\\Whoops\\Run.php(370): Concrete\\Core\\Error\\Handler\\JsonErrorHandler->handle(Object(Whoops\\Exception\\ErrorException))\n#7 [internal function]: Whoops\\Run->handleException(Object(Whoops\\Exception\\ErrorException))\n#8 {main}\n thrown"]}

Type: Pre-Sale
Status: Resolved
masuda.akari
View Replies:
mnakalay replied on at Permalink Reply
mnakalay
Hello, I can't be sure because you didn't provide your environment information but it seems you're using PHP8.

If that's correct, I'm afraid the package is not ready for PHP8 yet, you'd have to stick with PHP 7.

I'm planning on making it work with PHP 8 but I might need 2 or 3 weeks.
masuda.akari replied on at Permalink Reply
masuda.akari
Thank you for an answer.
We use PHP 8 in our environment.
Do you mean that the version that works with PHP 8 will be released around October 24?
mnakalay replied on at Permalink Reply
mnakalay
Maybe. I don't have many requests for that yet but I'm working on it. If my normal workload allows, I hope it will be ready around that time
masuda.akari replied on at Permalink Reply
masuda.akari
All right. I'll wait for it.
Thank you.
mnakalay replied on at Permalink Reply
mnakalay
Hello,

I went ahead and fixed it. Please update to version 2.1.0 and it should all be working with PHP 8.

Please let me know if there's any other issue.
masuda.akari replied on at Permalink Reply
masuda.akari
Thank you for your quick response.
I'll try.

concrete5 Environment Information

I installed 2FA Two-Factor Login Security, but the user's 2FA add-on cannot be enabled and an exception occurs.

Browser User-Agent String

Chrome/106.0.0.0

Hide Post Content

This will replace the post content with the message: "Content has been removed by an Administrator"

Hide Content

Request Refund

You may not request a refund that is not currently owned by you.