Re: Securing PHP



..oO(Gordon Burditt)

It becomes a better test when you check HTTP_HOST variable.

This variable belongs to the HTTP request headers and is required to
tell a shared server (means: one IP address, multiple domains) which
domain the requesting user agent wants to access. Still there's not much
of a reason to check for it. If you're on a shared server and the
requesting bot doesn't send a HTTP_HOST header, it won't even be able

Minor nit: it's a Host: header, not a HTTP_HOST: header. All of
the HTTP header variables get HTTP_ prefixed to them when they
appear in $_SERVER[].

Correct. :)

Micha
.



Relevant Pages

  • Re: HttpWebRequest POST method Expect header bug
    ... At least this way I got the HTTP POST ... > the Expect header, an error status is received and the request also fails. ... > Compact Framework as the System.Net.ServicePointManager.Expect100Continue ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: URLConnection
    ... Wie z.B. eine HttpUrlConnection im Detail implementiert ist, ... Ich hatte ähnliches was du vorhast (Kontrolle über die Header) mit dem ... Apache http client gemacht. ...
    (de.comp.lang.java)
  • Re: HTTP problem, wrong characters sent (HTTP pros needed!)
    ... prints it out including the response header of the http protocol. ... You are attempting to write an HTTP client yourself. ... request, which means you _must_ implement some features as specified in the ... specification to be able to decode the response, ...
    (comp.lang.php)
  • Re: read receipts
    ... all Exchange MIME messages to the internet contain this header. ... If the header your partners are sending you is #2, ... read receipts to be returned to a requesting external company. ...
    (microsoft.public.exchange.admin)
  • Re: How to parse HTTP time header?
    ... header. ... about how some servers may still send badly format time headers. ... in the standard library for parsing RFC 2616 dates. ... When I faced the problem of parsing HTTP dates, I wrote my own function although this was in an application that was deliberately unforgiving of invalid input and therefore my code makes no allowances for it. ...
    (comp.lang.python)