PHP Dateien manchmal zum Download angeboten + include() - Problem

Apache, Lighttpd, nginx, Cherokee
Post Reply
moondancer
Posts: 10
Joined: 2004-04-12 17:55
 

PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by moondancer »

Hallo,

ich habe ein merkwürdiges Problem mit meiner PHP Installation (4.3.4 auf Suse 9.2 mit Apache/2.0.49). Sehr vereinzelt werden PHP Dateien zum Download angeboten. Auch das Installieren einer anderen PHP Version bringt keine Abhilfe.
Außerdem funktionieren include Befehle mit externen Zielen nicht mehr - also in der Form:

Code: Select all

include("http://url.de");
Hatte jemand von Euch schonmal solch ein Problem - ich bin ratlos..

Viele Grüße
Christian
blnsnoopy26
Posts: 660
Joined: 2002-10-19 14:01
 

Re: PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by blnsnoopy26 »

Man sollte auch mal die uralte phpversion wegwerfen und die neuste nehmen.

man suchfunktion.
moondancer
Posts: 10
Joined: 2004-04-12 17:55
 

Re: PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by moondancer »

wie bereits geschrieben brachte das auch keine Abhilfe. Parallel ist PHP5 als CGI-Version installiert - hier funktioniert alles.
blnsnoopy26
Posts: 660
Joined: 2002-10-19 14:01
 

Re: PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by blnsnoopy26 »

moondancer wrote:wie bereits geschrieben brachte das auch keine Abhilfe. Parallel ist PHP5 als CGI-Version installiert - hier funktioniert alles.
Du hast hier nicht die suche benutzt - garantiere ich dir zu 100%

edit: dann hättest du gefunden das die alte phpversion ein bug hat wo das abundzu mal vorkommt.
moondancer
Posts: 10
Joined: 2004-04-12 17:55
 

Re: PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by moondancer »

ja ok jetzt läuft alles - danke. Allerdings habe ich noch den Fehler bei include() von http Adressen - siehe oben. Hatte das schonmal jemand im Zusammenhang mit der PHP Konfiguration oder schaut das nach einem DNS Problem aus (sonst läuft alles korrekt).

Viele Grüße
Christian
djcrackman
Posts: 207
Joined: 2005-06-02 11:58
Contact:
 

Re: PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by djcrackman »

Funktioniert denn gethostbyname() bzw. ist HostNameLookup im Apache auf On?
moondancer
Posts: 10
Joined: 2004-04-12 17:55
 

Re: PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by moondancer »

ja, gethostbyname() funktioniert. :?
djcrackman
Posts: 207
Joined: 2005-06-02 11:58
Contact:
 

Re: PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by djcrackman »

Probier mal folgendes:

Code: Select all

<?php
error_reporting(E_ALL);
include 'http://www.rootforum.org';
?>
Gibt das eine Fehlermeldung aus?
Last edited by djcrackman on 2005-11-10 18:19, edited 1 time in total.
moondancer
Posts: 10
Joined: 2004-04-12 17:55
 

Re: PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by moondancer »

mmh dies gibt folgende Meldung:

Code: Select all

Warning: main(http://www.rootforum.org): failed to open stream: HTTP request failed! greater than L octets, d in /var/www/virtual/xxx.de/htdocs/test.php on line 12

Warning: main(): Failed opening 'http://www.rootforum.org' for inclusion (include_path='.:') in /var/www/virtual/xxx.de/htdocs/test.php on line 12
djcrackman
Posts: 207
Joined: 2005-06-02 11:58
Contact:
 

Re: PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by djcrackman »

Kannst eine phpinfo() online stellen und hier den Link posten?
moondancer
Posts: 10
Joined: 2004-04-12 17:55
 

Re: PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by moondancer »

jep:

http://e-personal.de/info.php

(Bitte nicht an der PHP-Version stören, ich habe von 4.3.4 bis 4.4.1 alle ausprobiert)
djcrackman
Posts: 207
Joined: 2005-06-02 11:58
Contact:
 

Re: PHP Dateien manchmal zum Download angeboten + include() - Problem

Post by djcrackman »

Hm ... zum Vergleich mal eine PHP 4.4.2-dev, die derzeit bei meinen Usern läuft: http://demo-php4.uttx.net

Wobei ich folgendes ausprobiert habe:

Ich hab in der httpd.conf HostnameLookups auf Off gestellt und es erneut getestet -> funktioniert mit folgendem Script:

Code: Select all

<?php

error_reporting(E_ALL);
echo file_get_contents( 'http://www.rootforum.org');

?>
Post Reply