[Solar-talk] Solar_Auth possible bug and questions

Paul M Jones pmjones at solarphp.com
Thu Jul 13 09:50:16 PDT 2006


Hi Rodrigo,

> Three Solar_Auth topics on this e-mail:
>
> 1. Session object destruction failed
> This error occurrence may be rare:
>
> Warning: session_regenerate_id() [function.session-regenerate-id]:
> Session object destruction failed in ...\Solar\Auth.php on line 421
>
> (PHP 5.1.2, Windows XP)

I think this is 5.1.2 specific.  I do very similar things on my Unix  
machines with 5.1.4 and don't get that error.  See this bug in PHP:

     http://bugs.php.net/bug.php?id=36872


> 2. Problems trying to login using pt_BR locale
...
> The user locale should always be specified in a global manner, right?

Yes,  I think this is best.  Two easy ways to do this:

(1) In your bootstrap front index.php script, immediately after you  
call Solar::start(), call Solar::setLocale('pt_BR').

(2) In your Solar.config.php file, set $config['Solar'] 
['locale_code'] = 'pt_BR'.

Either way, everything after that will use the pt_BR locale files.

Warning: you may have just volunteered to write new pt_BR  
translations.  ;-)


> 3. Persistent login
> Is there a plan to implement persistent login in Solar_Auth or this
> should be done in a per project basis?

I had not planned on it, but I can see where it would be useful.  If  
it turns out to be a reasonably secure option, it would be better to  
have a Solar-standard way of doing this than to leave it for  
individual projects; then we can have a secure process available for  
everyone.  However, I don't know how to implement it; I will read the  
link you provided and see what I can do, but I'd appreciate patches/ 
pointers/etc to help out.  :-)



--

Paul M. Jones  <http://paul-m-jones.com>

Solar: Simple Object Library and Application Repository
for PHP5.   <http://solarphp.com>

Savant: The simple, elegant, and powerful solution for
templates in PHP.   <http://phpsavant.com>




More information about the solar-talk mailing list