summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 079003b)
raw | patch | inline | side by side (parent: 079003b)
author | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 19 Feb 2008 15:55:02 +0000 (15:55 +0000) | ||
committer | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 19 Feb 2008 15:55:02 +0000 (15:55 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8964 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-core/include/class_gosaSupportDaemon.inc | patch | blob | history | |
gosa-core/include/class_socketClient.inc | patch | blob | history |
diff --git a/gosa-core/include/class_gosaSupportDaemon.inc b/gosa-core/include/class_gosaSupportDaemon.inc
index b712d7614f4cd04d8dd19ae71f7462c471231802..4427592eb54d17e10ad246cbb6da27c54d07b7b0 100644 (file)
}
+ static function ping($target)
+ {
+ if (tests::is_mac($target)){
+ /* Get communication object */
+ $d= new gosaSupportDaemon(TRUE,0.5);
+
+ $answer= $d->_send("<xml><header>gosa_ping</header><source>GOSA</source><target>$target</target></xml>", TRUE);
+ return (count($answer) ? TRUE:FALSE);
+ }
+
+ return (FALSE);
+ }
+
}
// vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
index 2812e26880eab4dd50b5455bc3d2eb204d4b7348..7219459bcedc32b237c4963a9bc7cd39af98aa30 100644 (file)
private function decrypt($data)
{
/* decrypt data */
- if($this->b_encrypt){
+ if($this->b_encrypt && strlen($data)){
$data = base64_decode($data);
mcrypt_generic_init($this->td, $this->ckey, $this->iv);
$data = mdecrypt_generic($this->td, $data);
}
}
if((microtime(TRUE) - $start) > $this->timeout ){
- trigger_error(sprintf("Exceeded timeout %f while reading from socket",$this->timeout));
break;
}
}