#39803 [Opn->Fbk]: fsockopen() bug
ID: 39803 Updated by: [EMAIL PROTECTED] Reported By: marcelo at tpn dot com dot br -Status: Open +Status: Feedback Bug Type: Sockets related Operating System: FreeBSD 5.3 PHP Version: 4.4.4 New Comment: So you're saying this problem exist in PHP 5.2.3 also? If so, please set the version in this report to "5.2.3, 4.4.7" Previous Comments: [2007-05-03 18:29:51] marcelo at tpn dot com dot br This is a PHP problem. I have both CGI and Apache Module. fsockopen() works on CGI mode, but doesn't in Apache Module. [2007-04-05 19:59:08] [EMAIL PROTECTED] >The system is always returning EINPROGRESS. Why is that PHP problem? Fix your system instead. [2007-04-05 13:39:29] marcelo at tpn dot com dot br An user could fix this problem in PHP 5 adding 3 lines of code in main/network.c. if (!asynchronous) { /* back to blocking mode */ RESTORE_SOCKET_BLOCKING_MODE(sockfd, orig_flags); } /* Start changes */ if (error == EINPROGRESS) { error = 0; } /* End changes */ if (error_code) { *error_code = error; } if (error && error_string) { *error_string = php_socket_strerror(error, NULL, 0); ret = -1; } return ret; I try to modify PHP 4 but the code is a bit different. Can you help me to fix this problem? The system is always returning EINPROGRESS. [2006-12-18 17:11:42] [EMAIL PROTECTED] I really doubt I can reproduce or investigate it with only an FTP account. When I said "account on this machine" I meant SSH access. [2006-12-13 14:30:38] marcelo at tpn dot com dot br Sent to [EMAIL PROTECTED] The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/39803 -- Edit this bug report at http://bugs.php.net/?id=39803&edit=1
#39803 [Opn->Fbk]: fsockopen() bug
ID: 39803 Updated by: [EMAIL PROTECTED] Reported By: marcelo at tpn dot com dot br -Status: Open +Status: Feedback Bug Type: Sockets related Operating System: FreeBSD 5.3 PHP Version: 4.4.4 New Comment: >The system is always returning EINPROGRESS. Why is that PHP problem? Fix your system instead. Previous Comments: [2007-04-05 13:39:29] marcelo at tpn dot com dot br An user could fix this problem in PHP 5 adding 3 lines of code in main/network.c. if (!asynchronous) { /* back to blocking mode */ RESTORE_SOCKET_BLOCKING_MODE(sockfd, orig_flags); } /* Start changes */ if (error == EINPROGRESS) { error = 0; } /* End changes */ if (error_code) { *error_code = error; } if (error && error_string) { *error_string = php_socket_strerror(error, NULL, 0); ret = -1; } return ret; I try to modify PHP 4 but the code is a bit different. Can you help me to fix this problem? The system is always returning EINPROGRESS. [2006-12-26 01:00:00] php-bugs at lists dot php dot net No feedback was provided for this bug for over a week, so it is being suspended automatically. If you are able to provide the information that was originally requested, please do so and change the status of the bug back to "Open". [2006-12-18 17:11:42] [EMAIL PROTECTED] I really doubt I can reproduce or investigate it with only an FTP account. When I said "account on this machine" I meant SSH access. [2006-12-18 17:03:42] marcelo at tpn dot com dot br Someone else can help me to fix this bug? [2006-12-14 13:28:18] marcelo at tpn dot com dot br Did you receive my e-mail? The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/39803 -- Edit this bug report at http://bugs.php.net/?id=39803&edit=1
#39803 [Opn->Fbk]: fsockopen() bug
ID: 39803 Updated by: [EMAIL PROTECTED] Reported By: marcelo at tpn dot com dot br -Status: Open +Status: Feedback Bug Type: Sockets related Operating System: FreeBSD 5.3 PHP Version: 4.4.4 New Comment: I really doubt I can reproduce or investigate it with only an FTP account. When I said "account on this machine" I meant SSH access. Previous Comments: [2006-12-18 17:03:42] marcelo at tpn dot com dot br Someone else can help me to fix this bug? [2006-12-14 13:28:18] marcelo at tpn dot com dot br Did you receive my e-mail? [2006-12-13 14:30:38] marcelo at tpn dot com dot br Sent to [EMAIL PROTECTED] [2006-12-13 13:27:31] [EMAIL PROTECTED] Sure. [2006-12-13 13:13:10] marcelo at tpn dot com dot br Can I send the account information to [EMAIL PROTECTED] for privacy? The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/39803 -- Edit this bug report at http://bugs.php.net/?id=39803&edit=1
#39803 [Opn->Fbk]: fsockopen() bug
ID: 39803 Updated by: [EMAIL PROTECTED] Reported By: marcelo at tpn dot com dot br -Status: Open +Status: Feedback Bug Type: Sockets related Operating System: FreeBSD 5.3 PHP Version: 4.4.4 New Comment: Sure. Previous Comments: [2006-12-13 13:13:10] marcelo at tpn dot com dot br Can I send the account information to [EMAIL PROTECTED] for privacy? [2006-12-13 10:09:48] [EMAIL PROTECTED] Please provide more information on how to reproduce it or an account on this machine. [2006-12-12 17:43:15] marcelo at tpn dot com dot br I'm using PHP 4.4.4, not PHP 5. network.c has two pieces that uses EINPROGRESS: if ((n = connect(sockfd, addr, addrlen)) < 0) { if (errno != EINPROGRESS) { return -1; } } if (ret == -1 && error == EINPROGRESS) { error = 0; goto retry_again; } Where should I put "if (error == EINPROGRESS) error = 0;" ? [2006-12-12 16:32:18] [EMAIL PROTECTED] Does the fix from http://bugs.php.net/bug.php?id=38568 work for you? [2006-12-12 16:19:34] marcelo at tpn dot com dot br Yes, I've disabled my firewall. I'm sure that isn't a firewall problem. The problem doesn't depend the hostname or IP address. I got the same error trying to connect to localhost, 127.0.0.1, 10.0.0.9 (internal network) This also didn't work: This also didn't work (connect to an internal server): But I can use socket_connect without problems. Example: I also can use "fetch" utility to get data from these servers. I also wrote a PERL script, and it worked. I also type in prompt "telnet 127.0.0.1 80", "telnet www.google.com 80", the connection was sucessfull. Only while I'm using fsockopen I got errors, always error returns 36 and error string returns "Operation now in progress". The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/39803 -- Edit this bug report at http://bugs.php.net/?id=39803&edit=1
#39803 [Opn->Fbk]: fsockopen() bug
ID: 39803 Updated by: [EMAIL PROTECTED] Reported By: marcelo at tpn dot com dot br -Status: Open +Status: Feedback Bug Type: Sockets related Operating System: FreeBSD 5.3 PHP Version: 4.4.4 New Comment: Please provide more information on how to reproduce it or an account on this machine. Previous Comments: [2006-12-12 17:43:15] marcelo at tpn dot com dot br I'm using PHP 4.4.4, not PHP 5. network.c has two pieces that uses EINPROGRESS: if ((n = connect(sockfd, addr, addrlen)) < 0) { if (errno != EINPROGRESS) { return -1; } } if (ret == -1 && error == EINPROGRESS) { error = 0; goto retry_again; } Where should I put "if (error == EINPROGRESS) error = 0;" ? [2006-12-12 16:32:18] [EMAIL PROTECTED] Does the fix from http://bugs.php.net/bug.php?id=38568 work for you? [2006-12-12 16:19:34] marcelo at tpn dot com dot br Yes, I've disabled my firewall. I'm sure that isn't a firewall problem. The problem doesn't depend the hostname or IP address. I got the same error trying to connect to localhost, 127.0.0.1, 10.0.0.9 (internal network) This also didn't work: This also didn't work (connect to an internal server): But I can use socket_connect without problems. Example: I also can use "fetch" utility to get data from these servers. I also wrote a PERL script, and it worked. I also type in prompt "telnet 127.0.0.1 80", "telnet www.google.com 80", the connection was sucessfull. Only while I'm using fsockopen I got errors, always error returns 36 and error string returns "Operation now in progress". [2006-12-12 15:42:40] [EMAIL PROTECTED] >I believe that if the code is the same, should produce the > same result, else there is a bug. No, it most likely means that it has nothing to do with this code and you're looking for a problem in wrong place. Have you already disabled your firewall? [2006-12-12 15:22:51] marcelo at tpn dot com dot br I don't understand. If worked with CGI but not as an Apache Module, why you don't consider this a bug? I believe that if the code is the same, should produce the same result, else there is a bug. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/39803 -- Edit this bug report at http://bugs.php.net/?id=39803&edit=1
#39803 [Opn->Fbk]: fsockopen() bug
ID: 39803 Updated by: [EMAIL PROTECTED] Reported By: marcelo at tpn dot com dot br -Status: Open +Status: Feedback Bug Type: Sockets related Operating System: FreeBSD 5.3 PHP Version: 4.4.4 New Comment: Does the fix from http://bugs.php.net/bug.php?id=38568 work for you? Previous Comments: [2006-12-12 16:19:34] marcelo at tpn dot com dot br Yes, I've disabled my firewall. I'm sure that isn't a firewall problem. The problem doesn't depend the hostname or IP address. I got the same error trying to connect to localhost, 127.0.0.1, 10.0.0.9 (internal network) This also didn't work: This also didn't work (connect to an internal server): But I can use socket_connect without problems. Example: I also can use "fetch" utility to get data from these servers. I also wrote a PERL script, and it worked. I also type in prompt "telnet 127.0.0.1 80", "telnet www.google.com 80", the connection was sucessfull. Only while I'm using fsockopen I got errors, always error returns 36 and error string returns "Operation now in progress". [2006-12-12 15:42:40] [EMAIL PROTECTED] >I believe that if the code is the same, should produce the > same result, else there is a bug. No, it most likely means that it has nothing to do with this code and you're looking for a problem in wrong place. Have you already disabled your firewall? [2006-12-12 15:22:51] marcelo at tpn dot com dot br I don't understand. If worked with CGI but not as an Apache Module, why you don't consider this a bug? I believe that if the code is the same, should produce the same result, else there is a bug. [2006-12-12 14:22:58] [EMAIL PROTECTED] Both CGI and Apache module share the same code for fsockopen(), so fsockopen() doesn't depend on the Server API used. [2006-12-12 14:10:09] marcelo at tpn dot com dot br More details: Using php-cgi, fsockopen works correctly. The build date of the PHP (Apache Module) and PHP-CGI is the same. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/39803 -- Edit this bug report at http://bugs.php.net/?id=39803&edit=1
#39803 [Opn->Fbk]: fsockopen() bug
ID: 39803 Updated by: [EMAIL PROTECTED] Reported By: marcelo at tpn dot com dot br -Status: Open +Status: Feedback Bug Type: Sockets related Operating System: FreeBSD 5.3 PHP Version: 4.4.4 New Comment: >I believe that if the code is the same, should produce the > same result, else there is a bug. No, it most likely means that it has nothing to do with this code and you're looking for a problem in wrong place. Have you already disabled your firewall? Previous Comments: [2006-12-12 15:22:51] marcelo at tpn dot com dot br I don't understand. If worked with CGI but not as an Apache Module, why you don't consider this a bug? I believe that if the code is the same, should produce the same result, else there is a bug. [2006-12-12 14:22:58] [EMAIL PROTECTED] Both CGI and Apache module share the same code for fsockopen(), so fsockopen() doesn't depend on the Server API used. [2006-12-12 14:10:09] marcelo at tpn dot com dot br More details: Using php-cgi, fsockopen works correctly. The build date of the PHP (Apache Module) and PHP-CGI is the same. [2006-12-12 12:58:52] marcelo at tpn dot com dot br Why socket_create() works and fsockopen() doesn't? If there is some wrong outside PHP, why just fsockopen fails? [2006-12-12 07:32:24] [EMAIL PROTECTED] Sorry, but your problem does not imply a bug in PHP itself. For a list of more appropriate places to ask for help using PHP, please visit http://www.php.net/support.php as this bug system is not the appropriate forum for asking support questions. Due to the volume of reports we can not explain in detail here why your report is not a bug. The support channels will be able to provide an explanation for you. Thank you for your interest in PHP. Please consult your system administrator on how to disable the firewall. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/39803 -- Edit this bug report at http://bugs.php.net/?id=39803&edit=1