Sorin Alexandru Pop
and 1 contributors

NAME

Plack::Middleware::ServerName - sets/fakes the name of the server processing the requests while it will try to rearrange the headers so that they can match the real webserver you want to fake

SYNOPSIS

  use Plack::Builder;

  builder {
      enable "Plack::Middleware::ServerName",
          name  => 'Apache/2.2.8',
          order => [ qw( Date Server Last-Modified ETag Content-Type ) ];
      $app;
  };

DESCRIPTION

Plack::Middleware::ServerName is a middleware that allows to fakes the response Server header by removing it ( if name is undef ) or setting it to a defined value.

CONFIGURATIONS

name
  name => 'Apache'
  name => 'My-Own-WebServer/0.02'

string that defines/fakes the server's name

order
  order => [ qw( Date Server Last-Modified ETag Accept-Ranges Content-Length Keep-Alive Connection Content-Type ) ]

arrayref with headers in the order that the server should return them this are also case sensitive as to how the server returns them

SEE ALSO

Plack::Middleware

AUTHOR

Sorin Pop <sorin.pop {at} evozon.com>

LICENSE

This software is copyright (c) 2011 by Sorin Pop.

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.