PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » Authentication » Auth » Bug #2764

Auth fails after first page without cookies

Details

Submitted2004-11-16 03:37 UTC
Fromjj03 at operamail dot com
Assignedyavo
StatusClosed
PackageAuth
PHP Version4.3.9
Roadmaps(Not assigned)

Comments

[2004-11-16 03:37 UTC] jj03 at operamail dot com

Description:
------------
Auth 1.3.0r3
On browsers without cookies, authentication succeeds for the first page, but then the session is already expired. Either login should fail, or it should switch to cookieless authentication mode (if it is configured to do so).

[2004-11-26 18:43 UTC] hanuman at mail dot inet dot hr

Same thing happened to me in version 1.2.3.

Browser cookies were enabled, but I had output_buffeing off in PHP.ini. That disabled auth from sending cookies.

solution was to turn on output_buffering but you should put that somewhere in the documentation.

[2005-02-14 22:31 UTC] ojai at nerim dot net

Similar behaviour in here.

Actually it comes from one of my includes which starts output (spaces, etc...) before Auth calls session_start().

The problem is that it silently fails to set the cookie, and I have to login again between every page (I have intentionally disabled session.use_trans_sid). Then I start to wonder where this mysterious behaviour comes from. No warning, no notice, nothing.

This can be fixed by removing the @ which stands in front of session_start().

Could anyone please tell me why we need to suppress such useful PHP warnings as : Cannot modify header information - headers already sent by (output started at <script>:<line_no>) ??