Arbit - project tracking

Arbit - project tracking

#36: Broken OpenID server leads to arbit exception

Issue attachments

Issue revisions

  • new by thkoch at 2008-O-23 11:45
  • assigned by Kore Nordmann at 2008-O-23 17:28
  • assigned by Kore Nordmann at 2008-O-23 17:32
  • assigned by Kore Nordmann at 2008-O-23 17:33
  • assigned by Kore Nordmann at 2008-O-23 17:33
  • closed by Kore Nordmann at 2008-O-24 14:02
Type bug bug
State closed closed
Priority low low
Resolution fixed fixed
Assigned to Kore Nordmann
Scheduled for 0.1-alpha
Affected versions 0.0-dev, Latest SVN
Affected components Modules / Tracker
Last change Friday 24 October 2008 14:02:52 UTC by Kore Nordmann

Short description

I tried to register with arbit with my openId thomas.koch.ro. Since ssl wasn't set up the process failed, but should fail more gracefully. The Exception was:

                        exception 'arbitPhpErrorException' with message 'A PHP error occured: Warning: fsockopen() [<a href='function.fsockopen'>function.fsockopen</a>]: unable to connect to ssl://thomas.koch.ro:443 (Connection refused)' in /var/www/arbit/trunk/libraries/ezc/Authentication/src/filters/openid/openid_filter.php:861
Stack trace:
#0 [internal function]: arbitErrorHandler(2, 'fsockopen() [<a...', '/var/www/arbit/...', 861, Array)
#1 /var/www/arbit/trunk/libraries/ezc/Authentication/src/filters/openid/openid_filter.php(861): fsockopen('ssl://thomas.ko...', 443, 111, 'Connection refu...', 3)
#2 /var/www/arbit/trunk/libraries/ezc/Authentication/src/filters/openid/openid_filter.php(547): ezcAuthenticationOpenidFilter->checkSignature('http://thomas.k...', Array)
#3 /var/www/arbit/trunk/libraries/ezc/Authentication/src/authentication.php(241): ezcAuthenticationOpenidFilter->run(Object(ezcAuthenticationIdCredentials))
#4 /var/www/arbit/trunk/classes/controller/core/user/openid.php(169): ezcAuthentication->run()
#5 /var/www/arbit/trunk/classes/controller/core.php(875): arbitCoreModuleUserOpenIDAuthentification->handleCustom(Object(arbitHttpRequest), Object(arbitViewModuleModel))
#6 [internal function]: arbitCoreModuleController->__call('openid', Array)
#7 /var/www/arbit/trunk/classes/controller/project.php(70): arbitCoreModuleController->openid(Object(arbitHttpRequest))
#8 /var/www/arbit/trunk/classes/controller/project.php(140): arbitProjectController->callModuleController('core', Object(arbitHttpRequest))
#9 [internal function]: arbitProjectController->__call('core', Array)
#10 /var/www/arbit/trunk/classes/router/manager.php(199): arbitProjectController->core(Object(arbitHttpRequest))
#11 /var/www/arbit/trunk/classes/router/manager.php(149): arbitRoutingManager::handle(Object(arbitHttpRequest))
#12 /var/www/arbit/trunk/htdocs/index.php(66): arbitRoutingManager::routeUrl('/arbit/core/ope...')
#13 {main}



And the request:

# *properties =>
        * subaction => index
        * language =>
                  o 0 =>
                                + value => de-de
                                + priority => 1
                  o 1 =>
                                + value => de
                                + priority => 0.8
                  o 2 =>
                                + value => en-us
                                + priority => 0.5
                  o 3 =>
                                + value => en
                                + priority => 0.3
        * charset =>
                  o 0 =>
                                + value => *
                                + priority => 1
                  o 1 =>
                                + value => utf-8
                                + priority => 1
        * encoding =>
                  o 0 =>
                                + value => deflate
                                + priority => 1
                  o 1 =>
                                + value => gzip
                                + priority => 1
        * type =>
                  o 0 =>
                                + value => application/xhtml+xml
                                + priority => 1
                  o 1 =>
                                + value => text/html
                                + priority => 1
                  o 2 =>
                                + value => application/xml
                                + priority => 0.9
                  o 3 =>
                                + value => */*
                                + priority => 0.8
        * extension => Unknown.
        * root => /
        * controller => arbit
        * action => core
        * parameters =>
                  o nonce => 912144
                  o openid_mode => id_res
                  o openid_identity => http://thomas.koch.ro/MyID.config.php
                  o openid_assoc_handle => 9d501a0572df7c587db1e8bf028b64f9
                  o openid_return_to => http://tracker.arbitracker.org/arbit/core/openid?nonce=912144
                  o openid_sreg_nickname => thkoch2001
                  o openid_sreg_fullname => Thomas Koch
                  o openid_signed => mode,identity,assoc_handle,return_to,sreg.nickname,sreg.fullname
                  o openid_sig => 0hph8aWtHWtVIDnRPZsxqY2KvNI=
# subaction => openid
# root =>


Steps to reproduce

try to register with a broken openid server, which does not support SSL

Expected behaviour

some error message: openid server broken!

  • Kore Nordmann at Thursday 23 October 2008 17:32:52 UTC

    Fixed markup, scheduled for 0.1-alpha.

  • Kore Nordmann at Thursday 23 October 2008 20:46:06 UTC

    This is a problem with the error handler, which does not handle silenced errors (@) properly. And such fsockopen() errors are not possible to handle properly otherwise. Normally this would be handled properly in ezcAuthentification, but the arbit error handling interferes. Checking for the error level currently causes a segfault in PHP. The patch will be attached but not added until the segfault is fixed in PHP.

  • Kore Nordmann at Thursday 23 October 2008 21:34:11 UTC

    Fixed in revision #736 - the problem was not where it has been assumed.

    The current fix is serious hack and requires upstream fixing, issue will be left open until that has been resolved upstream.

  • Kore Nordmann at Friday 24 October 2008 14:02:52 UTC

    Really fixed in revision #738.