Permalink
Browse files

Add HTTP_AUTHORIZATION to $env before calling run_app. This is necess…

…ary as Catalyst::Request filters out headers that don't match /^(HTTP|CONTENT|COOKIE)/i, and without the Authorization header Catalyst::Authentication::Credential::HTTP can't do its work.
  • Loading branch information...
1 parent 41a6c51 commit 42c9527033ebcd972212aa570ddc2328745bf650 Ray Miller committed Jul 12, 2012
Showing with 4 additions and 0 deletions.
  1. +4 −0 lib/Plack/Handler/FCGI.pm
@@ -133,6 +133,10 @@ sub run {
$env->{PATH_INFO} = '';
}
+ if (defined(my $HTTP_AUTHORIZATION = $env->{Authorization})) {
+ $env->{HTTP_AUTHORIZATION} = $HTTP_AUTHORIZATION;
+ }
+
my $res = Plack::Util::run_app $app, $env;
if (ref $res eq 'ARRAY') {

0 comments on commit 42c9527

Please sign in to comment.