Releases: ChristianRiesen/otp
Minimum PHP version raised to 5.6
Thank you @phil-davis for the PR
Some documentation changes
The only "functional" change is that one parameter has been changed to string, in a doc block, which should quiet down perhaps some quality checkers.
Enable more algos
You can now also use more algorithms that are part of the RFC specs.
Thanks to @fkooman for the PR!
Make code 2038 safe
On a 64 bit PHP with a high enough PHP version this code is now 2038 safe.
Thanks to @fkooman for the contribution!
Urlencode labels
Labels are now urlencoded which should return a correct url for external use with QR codes (google authenticator etc)
Thank you @steffenweber for the contribution!
Constant time compare and dependencies upgrade
Thanks to @fkooman for widening the scope of which PHP unit versions this works with in development and for replacing the constant time compare with a more general solution (which also should perform better, if you don't need the polyfill).
Better random compatibility and constant time encoding
Thanks to @fkooman for the merge request!
Add time drift
For those who have issues with time drift, you can now set an offset on the Otp class to compensate, in case your hoster doesn't keep it's server time properly in check.
Thanks to @mithodin for the pull request.
Add image option to google authenticator
Thanks to @SamuelDauzon for the idea.
Added Resync helper for counter based hotp
The counter based otp now has a resync function that allows you to specify a "counterwindow", similar to what the drift does on timer based ones, except only forward. So if your otp is out of sync, you can match one with this function, which then returns the counter it matched on for you to save the new value (or returns false if it doesn't match).
Thanks to @therealssj for the pull request!