Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:55301 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 8267 invoked from network); 8 Sep 2011 06:49:54 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 8 Sep 2011 06:49:54 -0000 Authentication-Results: pb1.pair.com header.from=karoly@negyesi.net; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=karoly@negyesi.net; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain negyesi.net from 209.85.216.170 cause and error) X-PHP-List-Original-Sender: karoly@negyesi.net X-Host-Fingerprint: 209.85.216.170 mail-qy0-f170.google.com Received: from [209.85.216.170] ([209.85.216.170:50467] helo=mail-qy0-f170.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id E7/F2-05788-D85686E4 for ; Thu, 08 Sep 2011 02:49:53 -0400 Received: by qyl38 with SMTP id 38so140916qyl.8 for ; Wed, 07 Sep 2011 23:49:46 -0700 (PDT) Received: by 10.224.196.7 with SMTP id ee7mr236549qab.85.1315464586533; Wed, 07 Sep 2011 23:49:46 -0700 (PDT) Received: from mail-qy0-f177.google.com (mail-qy0-f177.google.com [209.85.216.177]) by mx.google.com with ESMTPS id hf4sm2471173qab.4.2011.09.07.23.49.45 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 07 Sep 2011 23:49:45 -0700 (PDT) Received: by qyk2 with SMTP id 2so243850qyk.8 for ; Wed, 07 Sep 2011 23:49:43 -0700 (PDT) Received: by 10.229.61.162 with SMTP id t34mr222759qch.93.1315464583102; Wed, 07 Sep 2011 23:49:43 -0700 (PDT) MIME-Version: 1.0 Received: by 10.229.168.137 with HTTP; Wed, 7 Sep 2011 23:49:23 -0700 (PDT) Date: Wed, 7 Sep 2011 23:49:23 -0700 Message-ID: To: internals@lists.php.net Content-Type: text/plain; charset=ISO-8859-1 Subject: Are all HTTP headers registered in SERVER? From: karoly@negyesi.net (Karoly Negyesi) Hi, It seems to be the case but this is not documented anywhere on php.net. Instead http://php.net/manual/en/function.apache-request-headers.php say "You can also get at the value of the common CGI variables by reading them from the environment". This comment http://www.php.net/manual/en/reserved.variables.server.php#87195 from 2008 concurs. Zend and Symphony both seems to be happy to read even X- custom headers from SERVER without bothering with apace_request_headers() or anything like that. I have tried to read some SAPI code and while most of them are a bit obscure, to the best of my understanding at least nsapi.c copies every request header (ok, there are very few exceptions, but certainly doesnt care about custom ones). So... is this official enough that I can amend the reserved.variables.server.php and the function.apache-request-headers.php pages stating that every HTTP header including custom ones can be found In SERVER (with the odd security exceptions)? Thanks Karoly Negyesi