#Wordpress
Before use authenticator, user must install md5 plugins to wordpress.
#Prosody
##Require library
- LuaDBI with MySQL.
- Wordpress must install MD5 Password Hashes.
##How to use
-
Copy mod_auth_wordpress.lua to prosody plugins folder.
-
Add authentication to VirtualHost and change mysql configuration to wordpress database.
VirtualHost "sample.com" authentication = "wordpress"; wordpress = { host = "localhost"; port = 3306; database = "wordpress"; username = "username"; password = "password"; prefix = "wp_"; };
-
If you want to use groups with Wordpress UAM Plugins, enable wordpress_mysql_groups in VirtualHost.
VirtualHost "sample.com" wordpress = { ... groups = true; }
-
Restart prosody.
#Darwin Calendar Server
##How to use
-
Copy wordpress.py and wordpressmysql.py to twistedcaldav/directory directory in calendar server library directory.
-
Add wordpress directory service in caldavd.plist like below.
<!-- WordPress MySQL Directory Service --> <key>DirectoryService</key> <dict> <key>type</key> <string>twistedcaldav.directory.wordpressmysql.WordpressMySQLDirectoryService</string> <key>params</key> <dict> <key>host</key> <string>localhost</string> <key>username</key> <string>wordpress_mysql_username</string> <key>password</key> <string>wordpress_mysql_password</string> <key>database</key> <string>wordpress_database</string> <key>prefix</key> <string>wp_</string> </dict> </dict>
-
Restart calendar server.
##How to test
- Copy wordpress*.py and test/test_wordpress*.py to CalendarServer-2.4/twistedcaldav/directory
- Run ./test twistedcaldav.directory.test.test_wordpressdirectory or twistedcaldav.directory.test.test_wordpressmysqldirectory