DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:twofactor

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
plugin:twofactor [2018-06-22 06:02] – reverting version change to allow extension author to update nosbigplugin:twofactor [2018-07-25 06:08] – Pushed update 18-07-25 wilminator
Line 6: Line 6:
 email      : michael.wilmes@gmail.com  email      : michael.wilmes@gmail.com 
 type       : Action Admin type       : Action Admin
-lastupdate : 2018-06-21a+lastupdate : 2018-07-25
 compatible : 2015-08-10a "Detritus", 2016-06-26 "Elenor Of Tsort", 2017-02-19b "Frusterick Manners" compatible : 2015-08-10a "Detritus", 2016-06-26 "Elenor Of Tsort", 2017-02-19b "Frusterick Manners"
 depends    : attribute depends    : attribute
Line 23: Line 23:
 ===== Summary ===== ===== Summary =====
  
-This module provides a two factor authentication framework to a wiki. It is designed to work with any wiki-based authentication mechanism (sorry Apache authentication users, I have not tested it for you). This module requires at least one Two Factor authentication module (listed below) in order to work.+This module provides a two factor authentication framework to a wiki. It is designed to work with any wiki-based authentication mechanism that supports the 'getUsers' method (see below for additional information). This module requires at least one Two Factor authentication module (listed below) in order to work.
  
-===== MAJOR REVISION =====+===== ANOTHER MAJOR REVISION =====
  
-As of 2016-01-06, I have completely overhauled this module and in order to use it you **will** need to add at least one supporting module. The benefit is that new modules can be added or updated without impacting other modules.+As of 2018-06-28, I have changed one of the methods in this module that breaks all prior versions of child modules.  I have updated all the modules, so as long as you update ALL twofactor modules, this should not be an issue.
  
 ===== Installation ===== ===== Installation =====
Line 76: Line 76:
   * ''enable'' -- Turn on or off all two factor authentication functionality. Default: ''off''   * ''enable'' -- Turn on or off all two factor authentication functionality. Default: ''off''
   * ''optinout'' -- Configure two factor features as ''optin'', ''optout'', and ''mandatory''. Default: ''optin''   * ''optinout'' -- Configure two factor features as ''optin'', ''optout'', and ''mandatory''. Default: ''optin''
-  * ''otpcontent'' -- The message to deliver to the user.'' $otp'' is replaced with the randomly generated code. Default: ''$otp'' is your verification code.+  * ''otpsubject'' -- A subject for OTP messages sent to the user. Default: OTP Verification Code 
 +  * ''otpcontent'' -- The message to deliver to the user. ''$otp'' is replaced with the randomly generated code. Default: ''$otp'' is your verification code.
   * ''generatorexpiry'' -- How many windows of time a GA code is valid for. This setting allows for a code to be useful for longer than its display time in GA. Very helpful for slow typing users of if a code is seen at the end of its display time. Default: ''2'' (the time displayed plus one more code)   * ''generatorexpiry'' -- How many windows of time a GA code is valid for. This setting allows for a code to be useful for longer than its display time in GA. Very helpful for slow typing users of if a code is seen at the end of its display time. Default: ''2'' (the time displayed plus one more code)
   * ''otplength'' -- Length of the randomly generated OTP. Default: ''7''   * ''otplength'' -- Length of the randomly generated OTP. Default: ''7''
   * ''sentexpiry'' -- Time in minutes that a sent OTP is valid for. Default: ''5''   * ''sentexpiry'' -- Time in minutes that a sent OTP is valid for. Default: ''5''
   * ''loginnotice'' (Not working yet) -- Send a notice on successful login to the user. Options are never (''none''), user choice (''user''), and always send a message (always). Default: ''user''   * ''loginnotice'' (Not working yet) -- Send a notice on successful login to the user. Options are never (''none''), user choice (''user''), and always send a message (always). Default: ''user''
 +  * ''loginsubject'' -- A subject for login confirmation messages sent to the user. Default: Login Successful 
 +  * ''logincontent'' -- The login message to deliver to the user.'' $time'' is replaced with the time  as generated by ''date(RFC_2822)''. Default: Your account was logged into at ''$time''
 +  * ''refreshexpiry'' -- A second login cookie is set by twofactor after the user has completed teh second login. This is the server-side timeout for that cookie, in minutes. Must be between 5 and 1440 minutes. Default: ''240'' 
 +  * ''logging_level'' -- Sets the logging level of the module. Supports five options: ''None'', ''Audit'', ''Audit+'', ''Debug'', and ''Debug+'' The ''Audit'' settings are appropriate as a login/logoff audit trail. ''Debug'' settings can be sent to me to assist in debugging. The "'Debug+' option will also provide stack traces.  The log file is intended to be CSV friendly. Default: ''None'' 
 +  * ''logging_path'' -- Path and filename of the log file written. Relative paths default to the wiki data directory. Absolute paths are honored to the extent PHP permits.  Default: ''2fa_audit.txt''
 ===== Development ===== ===== Development =====
  
Line 88: Line 93:
 ==== API ==== ==== API ====
  
-**NOTEWork In Progress** +The [[https://github.com/wilminator/dokuwiki-plugin-twofactor/blob/master/authmod.php|authmod.php]] file in the module is the base abstract class that can be used to add a custom authentication module Please review the file to learn more.
- +
-I am going to document the Two Factor module API here in order to provide all information about this plugin in one placeI am open to suggestions if a better location can be found.+
  
-=== Change Log ===+==== Change Log ====
  
 {{rss>https://github.com/wilminator/dokuwiki-plugin-twofactor/commits/master.atom date}} {{rss>https://github.com/wilminator/dokuwiki-plugin-twofactor/commits/master.atom date}}
  
-=== Known Bugs and Issues ===+==== Known Bugs and Issues ====
  
-  * The login notification does not work yet.+  * None that I'm aware of.  Visit the GitHub page for each of the modules for more information (or to let me know that something is broken).
  
-=== ToDo/Wish List ===+==== ToDo/Wish List ====
  
   * I've had a request to add Twilio and Plivo as supported two factor resources. After the redesign, I will look into it. I will need some help for testing, my personal budget is zero dollars and zilch cents.   * I've had a request to add Twilio and Plivo as supported two factor resources. After the redesign, I will look into it. I will need some help for testing, my personal budget is zero dollars and zilch cents.
plugin/twofactor.txt · Last modified: 2024-03-27 23:51 by andi

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki