Hi folks,
I'm in the process of writing a AuthPlugin for bbPress, so that the WordPress folks can do single sign-on between their user forums and their MediaWiki install. First release is here: http://codex.wordpress.org/User:RobLa/bbPress_Auth_for_MediaWiki
One thing I'm having trouble with is the case sensitivity issue. bbPress isn't case sensitive. MediaWiki is. This makes logging in relatively simple. As it turns out, I accidentally leveraged SQLs default case-insensitivity in my first crack at this.
So, I try logging in as "RobLa". My plugin checks the bbPress database, where I've registered "robla", and allows me to check my credentials there. All good, so "RobLa" created. Log out, log back in as "RobLa", and all works well. Yay!
However, I log back out and log back in as "RoBLA". It allows this too. Yay? Looking at the user db, it appears to have auto-created accounts for "RobLa" and "RoBLA". Boo!
My inclination is to add a new method AuthPlugin::getCanonicalName($username), which gets called from User::newFromName. That'll give my plugin (or any AuthPlugin) a crack at munging the name just before an account is created.
Before I do all of that, though, I'm hoping that there's a better approach that I'm not considering. Thoughts?
Rob
wikitech-l@lists.wikimedia.org