Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.6.4

Bug #9479 Typo in _checkServer causes failure - Fix Included.
Submitted: 2006-11-27 19:13 UTC
From: khanreaper at nerp dot net Assigned: aashley
Status: Closed Package: Auth (version 1.4.2)
PHP Version: 4.4.2 OS: Linux
Roadmaps: (Not assigned)    
Subscription  


 [2006-11-27 19:13 UTC] khanreaper at nerp dot net (Matt T. Proud)
Description: ------------ There is a typo in KADM5.php in the _checkServer function that causes this function to fail. The documentation for KADM5 states that the option to be passed for the Kerberos server should be "hostname," but this function refers to the option as "host," which consequently fails. I searched through the remainder of KADM5.php to see if "host" appeared, but it doesn't. Included is a patch to remedy this situation. It appears to still affect CVS code. Test script: --------------- --- KADM5.php.orig 2006-11-27 13:08:11.042770750 -0600 +++ KADM5.php 2006-11-27 13:08:13.790942500 -0600 @@ -153,13 +153,13 @@ * @access private */ function _checkServer() { - $fp = @fsockopen ($this->options['host'], 88, $errno, $errstr, $this->options['timeout']); + $fp = @fsockopen ($this->options['hostname'], 88, $errno, $errstr, $this->options['timeout']); if (is_resource($fp)) { @fclose($fp); } else { print_r($this->options); $message = "Error connecting to Kerberos V server " - .$this->options['host'].":".$this->options['port']; + .$this->options['hostname'].":".$this->options['port']; return PEAR::raiseError($message, 41, PEAR_ERROR_DIE); } } Expected result: ---------------- _checkServer actually works. Actual result: -------------- _checkServer fails.

Comments

 [2006-12-06 00:33 UTC] aashley at php dot net (Adam Ashley)
This bug has been fixed in CVS. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better.