- First commit to issue fork.
- Merge request !109Add ParagonIE Encoding dependency to composer.json. β (Open) created by seeduardo
We were experiencing the following error on our D10.3.10 site with TFA on 8.x-1.9 (full stack trace to follow in image at bottom):
Error: Class "ParagonIE\ConstantTime\Encoding" not found in Drupal\tfa\Plugin\TfaValidation\TfaTotpValidation->validate() (line 316 of modules/contrib/tfa/src/Plugin/TfaValidation/TfaTotpValidation.php).
We fixed it by requiring 'paragonie/constant_time_encoding' on the whole project, but really it seems to me from reading through this issue and the other related issues sprouting from/to it (principally TFA issue #2866841 β and Google Authenticator issue #2880601 β ) that said dependency should be brought into the codebase just by TFA itself. Hence, I added it to the composer.json and raised this merge request. I've tested it locally and it works, though I accept there may be some reason it was excluded or some other better solution - please do let me know if so.
Finally, I did and still do wonder why nobody else has reported the problem we had, that I could find anyway, especially seeing as this closed issue is so many years old now. My only guess so far is that all other projects in similar circumstances already have something else in their codebase pulling in the dependency. Any other ideas? Apologies if I've missed something glaringly obvious and many thanks in advance for any assistance or further info.
Full error:
- πΊπΈUnited States cmlara
@seeduardo:
I suggest opening a new issue as this one was closed as fixed years ago.
Many thanks @cmlara, I actually have already created issue #3498141 π ParagonIE\ConstantTime\Encoding dependency not installed from TFA Needs review - I thought that by raising the merge request here, it would reopen the issue, but then realized only module maintainers can do that, and didn't have the time to create the new issue until now. Thanks anyway for your comment and I don't suppose you have any input on the matter, particularly whether the change is correct or why the issue appears to have gone undetected (if even worthy of note now) for 7+ years?
I guess now that the link to the new issue is in this comment and the link to this issue is in the description of the new one, I will stop posting here - apologies if I've created any unnecessary noise for anyone up till now.