php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #4115 fsockopen causes script to exit
Submitted: 2000-04-12 07:04 UTC Modified: 2002-10-01 13:27 UTC
From: nemanjas at fon dot fon dot bg dot ac dot yu Assigned:
Status: Wont fix Package: Other
PHP Version: 3.0.16 OS: NT4 SP5
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: nemanjas at fon dot fon dot bg dot ac dot yu
New email:
PHP Version: OS:

 

 [2000-04-12 07:04 UTC] nemanjas at fon dot fon dot bg dot ac dot yu
It seem if you pass invalid host name to fsockopen, and you are online, script crashes. If offline all is ok.
Example:
$sock = fsockopen($ns, 53, $error, $errstr, 60);

if(!$sock) {
   printf("Nije uspela konekcija!<br>\n");
   return -1;
} 
else {
}

if ns is invalid like yuo have 2 dots in name script do a printf and exit's form script (this was a function).
It seems if lookup fails, there are problems.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-10-01 13:27 UTC] hholzgra@php.net
We are sorry, but can not support PHP 3 related problems anymore.
Momentum is gathering for PHP 5, and we think supporting PHP 3 will
lead to a waste of resources which we want to put into getting PHP 5
ready. Ofcourse PHP 4 will will continue to be supported for the
forseeable future.

... might as well have been winsock problem
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 18 08:02:42 2024 UTC