David Cook
6a0955946e
This change adds a mfa_range configuration option for TOTP to koha-conf.xml, and overrides the "verify" method from Auth::GoogleAuth in order to provide a new default for "range" Test plan: 0. Apply the patch 1. koha-plack --restart kohadev 2. Go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=TwoFactorAuthentication 3. Change the syspref to "Enable" 4. Go to http://localhost:8081/cgi-bin/koha/members/moremember.pl?borrowernumber=51 5. Click "More" and "Manage two-factor authentication" 6. Register using an app 7. In an Incognito window, go to http://localhost:8081/cgi-bin/koha/mainpage.pl 8. Sign in with the "koha" user 9. Note down a code from your Authenticator app 10. Wait until after 60 seconds and try it 11. Note it says "Invalid two-factor code" 12. Try a new code from the app 13. Note that it works 14. Add <mfa_range>10</mfa_range> to /etc/koha/sites/kohadev/koha-conf.xml 15. Clear memcached and koha-plack --restart kohadev 16. Sign in with the "koha" user 17. Note down a code from your Authenticator app 18. Wait 4 minutes and then try it 19. Note that it works 20. Disable your two-factor authentication and click to re-enable it 21. Use a code older than 60 seconds when registering for the two factor authentication 22. Note that the code works Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> |
||
---|---|---|
.. | ||
AuthoritiesMarc | ||
Barcodes | ||
ClassSortRoutine | ||
ClassSplitRoutine | ||
Creators | ||
External | ||
Form | ||
Heading | ||
ILSDI | ||
Installer | ||
Labels | ||
Linker | ||
Members | ||
OAI | ||
Output | ||
Patroncards | ||
Reports | ||
Search | ||
Serials | ||
SIP | ||
Utils | ||
Accounts.pm | ||
Acquisition.pm | ||
Auth.pm | ||
Auth_cas_servers.yaml.sample | ||
Auth_with_cas.pm | ||
Auth_with_ldap.pm | ||
Auth_with_shibboleth.pm | ||
AuthoritiesMarc.pm | ||
Barcodes.pm | ||
Biblio.pm | ||
Breeding.pm | ||
Budgets.pm | ||
Calendar.pm | ||
Charset.pm | ||
Circulation.pm | ||
ClassSortRoutine.pm | ||
ClassSource.pm | ||
ClassSplitRoutine.pm | ||
Context.pm | ||
Contract.pm | ||
CourseReserves.pm | ||
Creators.pm | ||
Heading.pm | ||
HoldsQueue.pm | ||
HTML5Media.pm | ||
ImportBatch.pm | ||
ImportExportFramework.pm | ||
InstallAuth.pm | ||
Installer.pm | ||
ItemCirculationAlertPreference.pm | ||
Items.pm | ||
Koha.pm | ||
Labels.pm | ||
Languages.pm | ||
Letters.pm | ||
Linker.pm | ||
Log.pm | ||
MarcModificationTemplates.pm | ||
Matcher.pm | ||
Members.pm | ||
Message.pm | ||
Output.pm | ||
Overdues.pm | ||
Patroncards.pm | ||
Record.pm | ||
Reports.pm | ||
Reserves.pm | ||
Ris.pm | ||
RotatingCollections.pm | ||
Scheduler.pm | ||
Scrubber.pm | ||
Search.pm | ||
Serials.pm | ||
Service.pm | ||
ShelfBrowser.pm | ||
SMS.pm | ||
SocialData.pm | ||
Stats.pm | ||
Suggestions.pm | ||
Tags.pm | ||
Templates.pm | ||
TmplToken.pm | ||
TmplTokenType.pm | ||
TTParser.pm | ||
UsageStats.pm | ||
XISBN.pm | ||
XSLT.pm |