====== Login/Logoff Logging Plugin ====== ---- plugin ---- description: Logs all login/logout actions and usage of admin tools with time, IP and username author : Andreas Gohr email : andi@splitbrain.org type : action, admin lastupdate : 2020-11-16 compatible : 2020-07-29 "Hogfather", 2018-04-22 "Greebo", Frusterick Manners, "Elenor of Tsort", Detritus,, Igor depends : conflicts : similar : tags : authentication, logging downloadurl: https://github.com/splitbrain/dokuwiki-plugin-loglog/zipball/master sourcerepo : https://github.com/splitbrain/dokuwiki-plugin-loglog/ bugtracker : https://github.com/splitbrain/dokuwiki-plugin-loglog/issues donationurl: http://donate.dokuwiki.org/loglog screenshot_img: plugin:loglog.png ---- This plugin will log all logins, logouts and failed login attempts to ''data/cache/loglog.log''. Optionally, you can configure the plugin to send warning emails when certain limits for those activities have been exceeded. The default limits are 10 failed login attempts and 50 successful logins per minute. The log can be viewed on the admin screen. A monthly report will be sent if you enter an email in the plugin configuration. ===== Download and Installation ===== Search and install the plugin using the [[plugin:extension|Extension Manager]]. Refer to [[:Plugins]] on how to install plugins manually. ==== Changes ==== {{rss>https://github.com/splitbrain/dokuwiki-plugin-loglog/commits/master.atom date}} ===== Custom Auth-Plugin logging ===== The plugin might fail to log logins made through auth plugins other than [[plugin:authplain]]. Plugin authors can make their plugins compatible by emitting a ''PLUGIN_LOGLOG_LOG'' event whenever they want to log a login/logout action. The event requires two fields in the ''$data'' array: ''message'' for the log message and ''user'' for the affected user. Here's an example from the [[plugin:sfauth|SalesForce Auth Plugin]]: $log = array('message' => 'logged in via Salesforce', 'user' => $this->user); trigger_event('PLUGIN_LOGLOG_LOG',$log); The message can contain whatever you want to log. However, if you use the following strings in your message, an appropriate icon is associated with your message: ^ message part ^ icon ^ | ''logged off'' | {{https://raw.githubusercontent.com/splitbrain/dokuwiki-plugin-loglog/master/pix/off.png}} | | ''logged in permanently'' | {{https://raw.githubusercontent.com/splitbrain/dokuwiki-plugin-loglog/master/pix/perm.png}} | | ''logged in'' | {{https://raw.githubusercontent.com/splitbrain/dokuwiki-plugin-loglog/master/pix/temp.png}} | | ''failed'' | {{https://raw.githubusercontent.com/splitbrain/dokuwiki-plugin-loglog/master/pix/error.png}} |