Authentication broken with current Dokuwiki version

Moderator: fanno

Forum rules
Please post all the bugs you encounter on our issue tracker.

Authentication broken with current Dokuwiki version

Postby webtech on Sat Jul 02, 2011 2:17 am

Please fill up the following form to enjoy free support from our Team. No Support will be provided in case this form is not filled up!

1. Have you searched the forums and checked the documentation section for a solution?

yes

2. Please summarize your problem in a few lines.

JFusion does not authenticate into Dokuwiki for the current DokuWiki version, dokuwiki-2011-05-25a.tgz “Rincewind”.

3. What steps will reproduce the problem?

Upgrade Dokuwiki to current version, log into Joomla Frontend, do NOT check "stay logged in".

4. What is the expected output? What do you see instead?

User should be authenticated in Joomla frontend and Dokuwiki, but is only authenticated in the frontend. Dokuwiki just shows login screen.

The problem seems to be that Dokuwiki changed its authentication cookie to include the session id in the salt, see dokuwiki/inc/auth.php:

Code: Select all
function auth_cookiesalt($addsession=false){
    global $conf;
    $file = $conf['metadir'].'/_htcookiesalt';
    $salt = io_readFile($file);
    if(empty($salt)){
        $salt = uniqid(rand(),true);
        io_saveFile($file,$salt);
    }
    if($addsession){
        $salt .= session_id(); //COMMENT THIS OUT
    }
    return $salt;
}


If the indicated line is commented out, authentication is compatible with the old scheme. There doesn't seem to be an easy fix: If the JFusion part is updated to include the new salt, it works (in Frameless mode) until one tries to upload a file using the media manager. Then the authentication is lost, since the media manager is called separately from Joomla, therefore doesn't share the Joomla session id anymore and creates its own (differently named) session, which has a different session id and therefore doesn't accept the authentication cookie. I have no idea how to fix this without patching Dokuwiki.

5. You must include a printout of the login checker in the JFusion component.

Code: Select all
Joomla Version   1.5.23
PHP Version   5.2.12-nmm2
MySQL Version   5.0.51a-3ubuntu5.8-log
System Information   Linux XXXXXX 2.6.24-29-server #1 SMP Fri May 27 18:34:25 UTC 2011 x86_64
Browser Information
joomla authentication Plugin   Enabled
joomla user Plugin   Enabled
jcomments user Plugin   Enabled
jfusion user Plugin   Enabled
jfusion authentication Plugin   Enabled

JFusion Versions
JFusion Component Version    1.5.5-000 (Rev 2442:2452)
JFusion Authentication Plugin Version    1.5.5-000
JFusion User Plugin Version    1.5.5-000
JFusion Activity Module Version    1.5.5-000
JFusion Login Module Version    1.5.5-000
JFusion Search Plugin Version    1.5.5-000
JFusion Discussion Plugin Version    1.5.5-000

JFusion joomla_int Plugin
configuration   master 1
slave 0
dual_login 1
check_encryption 0
JFusion dokuwiki Plugin
configuration   master 0
slave 1
dual_login 1
check_encryption 0


Authentication Plugin
userid   64
activation   ""
username   ****
name   ****
password   66ce3c********
email   J**
block   0
group_name   Super Administrator
group_id   25
params   editor=jce expired= expired_time= admin_language= language= helpsite= timezone=1
password_salt   XG32*****
language   en-GB
credentialed_username   ****
password_clear   ******
   Authentication Plugin Success
Authentication Plugin Debug
0   joomla_int Password Encryption Check: 66ce3c******** vs 66ce3c********
1   joomla_int Password Encryption Check: Success


jfusion User Plugin
   User Plugin Success
User Plugin Debug
init   0 Using userinfo JFusion authentication plugin
joomlaid   64
dokuwiki User Update   0 A user has been found that matches the login details
1 Skipped the update of name
2 Skipped Password Update:Password already valid
dokuwiki User Details   
userid   ****
name   ****
username   ****
password   afda6d********
email   ****
group_id   0 admin
1 ausbilder
2 user
password_clear   ******
dokuwiki Session   
Created Cookies   
0   Name DW414b*************************
Value am**|0|cWVj************************
Expires 2012-07-01 04:01:42
Cookie Path /XXXXX/
Cookie Domain www.XXXX
User avatar
webtech
JFusion Newbie II
JFusion Newbie II
 
Posts: 11
Joined: Tue Mar 08, 2011 5:08 am

Re: Authentication broken with current Dokuwiki version

Postby fanno on Sat Jul 02, 2011 6:25 am

dokuwiki keeps changing things that breaks integration .... it never end's ..... this is not the first time cookies change .. or other things ..

i am really considering to stop supporting them.. no offense to you... it's just that every of their last like 4-5 versions have had something that breaks integration.

=(

please put this on the bug tracker, and i will see when i calm down a bit... i will take a look. but you are right ... i think patching dokuwiki might be the only choice ..

http://code.jfusion.org/projects/show/develop

-Thanks
Fanno
_________________________________
Developer
Specialist on SMF, DokuWiki , Mantis, Eventum, Mediawiki, Universal plugin


Review us at!
http://extensions.joomla.org/extensions/3723/details
User avatar
fanno
Developer
Developer
 
Posts: 7666
Joined: Wed Jan 07, 2009 4:38 pm
Location: Denmark, Copenhagen

Re: Authentication broken with current Dokuwiki version

Postby ALIENQuake on Sun Jul 24, 2011 11:13 am

That's sad to hear. Currently, JFusion supports only one Wiki system. If you want to drop DokuWiki, can you try to make integration with MediaWiki again ?
User avatar
ALIENQuake
JFusion Novice
JFusion Novice
 
Posts: 44
Joined: Sun Mar 13, 2011 1:59 pm

Re: Authentication broken with current Dokuwiki version

Postby fanno on Sun Jul 24, 2011 1:40 pm

we have a plugin for that in jfusion 1.6 Rc1
Fanno
_________________________________
Developer
Specialist on SMF, DokuWiki , Mantis, Eventum, Mediawiki, Universal plugin


Review us at!
http://extensions.joomla.org/extensions/3723/details
User avatar
fanno
Developer
Developer
 
Posts: 7666
Joined: Wed Jan 07, 2009 4:38 pm
Location: Denmark, Copenhagen

Re: Authentication broken with current Dokuwiki version

Postby ALIENQuake on Sun Jul 24, 2011 1:55 pm

That's fantastic news ! Can i use this plugin in JFusion 1.5.x :?:
User avatar
ALIENQuake
JFusion Novice
JFusion Novice
 
Posts: 44
Joined: Sun Mar 13, 2011 1:59 pm

Re: Authentication broken with current Dokuwiki version

Postby fanno on Sun Jul 24, 2011 2:02 pm

it should be combatible
Fanno
_________________________________
Developer
Specialist on SMF, DokuWiki , Mantis, Eventum, Mediawiki, Universal plugin


Review us at!
http://extensions.joomla.org/extensions/3723/details
User avatar
fanno
Developer
Developer
 
Posts: 7666
Joined: Wed Jan 07, 2009 4:38 pm
Location: Denmark, Copenhagen

Re: Authentication broken with current Dokuwiki version

Postby ALIENQuake on Sun Jul 24, 2011 2:14 pm

Great, let me do some test 8-)
User avatar
ALIENQuake
JFusion Novice
JFusion Novice
 
Posts: 44
Joined: Sun Mar 13, 2011 1:59 pm

Re: Authentication broken with current Dokuwiki version

Postby ALIENQuake on Sun Jul 31, 2011 3:47 pm

Can you help me with installing MediaWiki plugin into JFusion 1.5 ? I try to create plugin installation package and install it trough "JFusion Plugin Installer" but besides putting all files in zip i don't know what i should do.
User avatar
ALIENQuake
JFusion Novice
JFusion Novice
 
Posts: 44
Joined: Sun Mar 13, 2011 1:59 pm

Re: Authentication broken with current Dokuwiki version

Postby fanno on Sun Jul 31, 2011 4:26 pm

i am sorry i do not have any free time at the moment
Fanno
_________________________________
Developer
Specialist on SMF, DokuWiki , Mantis, Eventum, Mediawiki, Universal plugin


Review us at!
http://extensions.joomla.org/extensions/3723/details
User avatar
fanno
Developer
Developer
 
Posts: 7666
Joined: Wed Jan 07, 2009 4:38 pm
Location: Denmark, Copenhagen

Re: Authentication broken with current Dokuwiki version

Postby daniel9 on Thu Nov 10, 2011 2:52 pm

Can i use this plugin in JFusion 1.4.x ?
Thanks !
User avatar
daniel9
JFusion Newbie
JFusion Newbie
 
Posts: 1
Joined: Thu Nov 10, 2011 2:39 pm

Next

Return to DokuWiki

Who is online

Users browsing this forum: No registered users and 1 guest

cron