halt() not sending expected results when using HTTP_UNAUTHORIZED
Reported by TheIdeaMan | July 30th, 2009 @ 09:50 PM | in Release 0.4 - Fresh Mint And Ginger
I'm currently building a simple JSON API with Limonade, and I need authentication. I've setup Digest Authentication in PHP using the recommended code from the PHP manual: http://us.php.net/features.http-auth
However, my use of halt(HTTP_UNAUTHORIZED, 'Wrong Credentials!'); doesn't work and I get a 200 OK response with the text, "default_layout.php"
My expected result was a 401 Unauthroized header and my message text as the body.
I've done some digging, and I believe that halt is due for some refactoring (per the TODO in that function), so perhaps that's where things are breaking.
Thanks in advance for the bug fix. If I find a solution, I'll post the patch.
Limonade is off to a great start! Thanks.
Comments and changes to this ticket
-
Fabrice Luraine August 2nd, 2009 @ 01:20 PM
Hello,
i've relaesed the 0.4.1 version of Limonade. It fixes many bugs, included the #18. Can you tell me if it resolves your problem ?
Thks.
-
Fabrice Luraine September 19th, 2009 @ 04:58 PM
- State changed from new to resolved
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป
Limonade is a PHP micro-framework.