#20 ✓resolved
TheIdeaMan

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

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.

New ticket Create new ticket

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.

People watching this ticket

Pages