diff --git a/phpgwapi/inc/class.interserver.inc.php b/phpgwapi/inc/class.interserver.inc.php index 5a0ee6253e..405c0ac29e 100644 --- a/phpgwapi/inc/class.interserver.inc.php +++ b/phpgwapi/inc/class.interserver.inc.php @@ -221,11 +221,12 @@ $f = CreateObject('phpgwapi.xmlrpcmsg', $method_name, $arr,'struct'); } - $this->debug("
" . htmlentities($f->serialize()) . "\n",$debug); + $this->debug('
' . htmlentities($f->serialize()) . '' . "\n",$debug); $c = CreateObject('phpgwapi.xmlrpc_client',$this->urlparts['xmlrpc'], $hostpart, 80); $c->username = $this->sessionid; $c->password = $this->kp3; - $c->setDebug(1); +// _debug_array($c); + $c->setDebug(0); $r = $c->send($f); if (!$r) { diff --git a/phpgwapi/inc/class.xmlrpc_server.inc.php b/phpgwapi/inc/class.xmlrpc_server.inc.php index 5903cb36c0..ac57d9a556 100644 --- a/phpgwapi/inc/class.xmlrpc_server.inc.php +++ b/phpgwapi/inc/class.xmlrpc_server.inc.php @@ -25,6 +25,7 @@ class xmlrpc_server { var $dmap = array(); + var $authed = False; function xmlrpc_server($dispMap='', $serviceNow=0) { @@ -183,13 +184,16 @@ } if(!isset($dmap[$methName]['function'])) { - /* phpgw mod - fetch the (bo) class methods to create the dmap */ - $method = $methName; - $tmp = explode('.',$methName); - $methName = $tmp[2]; - $listmeth = $tmp[0] . '.' . $tmp[1] . '.' . 'list_methods'; - $dmap = ExecMethod($listmeth,'xmlrpc'); - $this->dmap = $dmap; + if($this->authed) + { + /* phpgw mod - fetch the (bo) class methods to create the dmap */ + $method = $methName; + $tmp = explode('.',$methName); + $methName = $tmp[2]; + $listmeth = $tmp[0] . '.' . $tmp[1] . '.' . 'list_methods'; + $dmap = ExecMethod($listmeth,'xmlrpc'); + $this->dmap = $dmap; + } } if (isset($dmap[$methName]['function'])) { @@ -222,15 +226,53 @@ $code = '$p = ' . $params . ';'; eval($code); $params = $p->getval(); + /* _debug_array($params); */ + if(gettype($params) == 'array') + { + @reset($params); + while(list($key,$val) = @each($params)) + { + if(gettype($val) == 'array') + { + @reset($val); + while(list($key1,$val1) = @each($val)) + { + $tmp = ''; + if(get_class($val1) == 'xmlrpcval') + { + $tmp[$key1] = $val1->getval(); + /* echo '