View Issue Details

IDProjectCategoryView StatusLast Update
0016076mantisbtbugtrackerpublic2014-12-22 08:24
Reporteroperljz Assigned Todregad  
PrioritynormalSeverityblockReproducibilityalways
Status closedResolutionno change required 
Product Version1.2.15 
Summary0016076: new revision wiki(dokuwiki-2013-05-10) integration with Mantis report error 'User authentication is temporarily unavailable'
Description

dokuwiki-2012-10-13 integration with Mantis is work better, but new version dokuwiki-2013-05-10a has report error 'User authentication is temporarily unavailable'.

Steps To Reproduce
  1. install dokuwiki-2013-05-10a ingtegration with mantis by follow the instruction http://www.mantisbt.org/wiki/doku.php/mantisbt:issue:7075

  2. login mantis and click button 'wiki' to login dokuwiki, wiki report error as below:
    User authentication is temporarily unavailable. If this situation persists, please inform your Wiki Admin.

Additional Information

i noticed that dokuwiki announce authentication backend has some changed in new revision wiki:
https://www.dokuwiki.org/changes#release_2013-05-10a_weatherwax

so i try to resolve this issue by modify wiki/conf/local.php as below:
$conf['authtype'] = 'mantis' --> $conf['authtype'] = 'authmantis'. but problem still occured.

TagsNo tags attached.

Relationships

related to 0008277 closeddregad dokuwiki integration: cannot login from wiki login page 

Activities

dregad

dregad

2013-06-20 10:02

developer   ~0037235

Last edited: 2013-06-20 10:06

If DokuWiki changed their authentication back-end, there's a good chance indeed that it would break the old code.

I don't have time to look into this at the moment, but if you do end-up fixing the mantis authentication plugin, please let us know.

Ref: https://www.dokuwiki.org/devel:auth_plugins#howto_update_your_old_backend

If not or until then, I guess you're stuck with the 2012-10-13 release.

dregad

dregad

2013-06-21 13:31

developer   ~0037245

I did a quick & dirty conversion of the old authentication back-end to the new plugin structure. This is provided "as-is", there may be issues with it as I did not have time to do much testing.

https://github.com/dregad/dokuwiki_mantis/tree/master/plugins/authmantis

Feedback welcome.

chrisnik

chrisnik

2013-06-23 07:17

reporter   ~0037250

Hello dregad,

Thank you for the updated authmantis plugin! Unfortunately I am still not getting it to work with the latest dokuwiki version.

I followed the instructions on http://www.mantisbt.org/wiki/doku.php/mantisbt:issue:7075:integration_with_dokuwiki?do=show
The only change is that I used the new authmantis plug in.

I then got the UTF8 redefinition errors described in 0011769 These I solved by implementing the workaround from 0011018 :

wrapping each utf8 function with
if(!function_exists('utf8_xxx')){
}

The next error I got is an empty page with this in the log:
Call to undefined function plugin_get_current() in /var/www/html/mantis/core/lang_api.php on line 278

It seems the problems are related to the to the following line:
require_once( MANTIS_ROOT . 'core.php' );

But my knowledge of php is limited and the things I tried did not help.

Do you perhaps know what the problem could be?

Regards,
Chris

dregad

dregad

2013-06-23 08:59

developer   ~0037251

@chrisnik

That wiki page needs to be updated.

Did you have a working setup before, or are you installing it from scratch ?

In the former case, you should just install the new plugin and change your config to use 'authmantis' instead of the old 'mantis' authentication back-end (this is the only thing I actually tested after building the new plugin, and it worked for me.

If you're installing from scratch, then you should add <pre>require_once( MANTIS_ROOT . 'core.php' );</pre> to your <i>local.protected.php</i> file, and forget about adding wrappers around utf8 functions - I don't think that's a good workaround as there are many other issues, with this approach, e.g. with definition of global variables.

chrisnik

chrisnik

2013-06-23 12:19

reporter   ~0037253

Hi dregad,

Thanks for your note!

I have working dokuwiki and mantis. Dokuwiki works when I comment the lines in local.protected.php.

If I include the line
<pre>require_once( MANTIS_ROOT . 'core.php' );</pre>
in local.protected.php, I get the following error:
'Undefined index: port' in '/var/www/html/dokuwiki/inc/init.php' line 447

Please note that I have both apps running under https - not sure if this makes a difference.

Tried changing line 447 to:
<pre>$port = isset($parsed_host['port']) ? $parsed_host['port'] : 443;</pre>, but then I got:

'A session had already been started - ignoring session_start()' in '/var/www/html/dokuwiki/inc/init.php' line 151

Not sure what else I can do.

Regards,
Chris

dregad

dregad

2013-06-26 12:40

developer   ~0037311

@chrisnik

Sorry but I am not able to reproduce the errors you describe. I setup a fresh Mantis and DokuWiki locally, with the following local.protected.php file

<pre>
<?php
define( 'MANTIS_ROOT', '/path/to/mantisbt/' );
define( 'MANTIS_URL', 'http://localhost/mantis/' );
require_once( MANTIS_ROOT . 'core.php' );
</pre>

All works fine for me (but I'm on HTTP, not HTTPS). However that error is benign (PHP Notice), so I would just ignore it.

With regards to the session_start message, Mantis does start a session when you include core.php so that would be the cause of the error, but again that's just a PHP Notice so I think it can safely be ignored. I submitted a pull request to Dokuwiki team to get rid of that [1], maybe they'll accept it.

In the meanwhile, you may want to change your error settings in config_inc.php to <pre>$g_display_errors['E_NOTICE'] = 'none';</pre>

[1] https://github.com/splitbrain/dokuwiki/pull/234

dregad

dregad

2013-08-12 03:43

developer   ~0037655

operljz,

You did not provide any feedback; I am therefore resolving this issue as "no change required".

Feel free to reopen the issue at a later time and provide the requested information.