Show
Ignore:
Timestamp:
02/11/10 17:34:27 (2 years ago)
Author:
gbastien
Message:

* Merged recent changes in the trunk into this branch
* New token architecture not yet fully functional, nor tested, but ...

  • can now edit token templates for different context of tokens (from the edit netork interface at the bottom of page)
  • Users connected through a wifidog gateway can view their connection token information
Files:
1 modified

Legend:

Unmodified
Added
Removed
  • branches/newtoken/wifidog/ws/index.php

    r1427 r1446  
    9595    $exceptionClass = get_class($e); 
    9696    if (!is_null($output)) { 
    97         echo $output->outputError(array('type' => $exceptionClass,  
     97        if ($exceptionClass == 'WSException') { 
     98            echo $output->outputError(array('type' => $exceptionClass,  
     99                                    'message' => sprintf(_("Web service exception:  %s (%s)"), $e->getMessage(), $e->getCode()))); 
     100        } else 
     101            echo $output->outputError(array('type' => $exceptionClass,  
    98102                                    'message' => sprintf(_("Detailed error was:  Uncaught %s %s (%s) thrown in file %s, line %d"),get_class($e), $e->getMessage(), $e->getCode(), $e->getFile(), $e->getLine()))); 
    99103    } else { 
    100         echo sprintf(_("Detailed error was:  Uncaught %s %s (%s) thrown in file %s, line %d"),get_class($e), $e->getMessage(), $e->getCode(), $e->getFile(), $e->getLine()); 
     104        if ($exceptionClass == 'WSException') { 
     105            echo sprintf(_("Web service exception:  %s => %s (%s)"),get_class($e), $e->getMessage(), $e->getCode(), $e->getFile(), $e->getLine()); 
     106        } else 
     107            echo sprintf(_("Detailed error was:  Uncaught %s %s (%s) thrown in file %s, line %d"),get_class($e), $e->getMessage(), $e->getCode(), $e->getFile(), $e->getLine()); 
    101108    } 
    102109 
     
    105112set_exception_handler('wifidog_exception_handler'); 
    106113 
    107 throw (new WSException(_("The Wifidog API module is not fit for production yet.  The source code has been released to share ideas and help development, but it has not been thoroughly tested yet and may represent a security issue for now.  If you'd like to test the module, you can do so by commenting this line in the auth server's source code.  But it is highly not advised to do so in a production environment for now.  Please stay tuned for more development"))); 
     114//throw (new WSException(_("The Wifidog API module is not fit for production yet.  The source code has been released to share ideas and help development, but it has not been thoroughly tested yet and may represent a security issue for now.  If you'd like to test the module, you can do so by commenting this line in the auth server's source code.  But it is highly not advised to do so in a production environment for now.  Please stay tuned for more development"))); 
    108115 
    109116$service->setParams($_GET);