diff --git a/netconf/Device.php b/netconf/Device.php index 1ac2179..6be2b12 100644 --- a/netconf/Device.php +++ b/netconf/Device.php @@ -133,7 +133,7 @@ public function Device_array(array $params) *operations. */ public function connect() { - $this->stream = expect_popen("ssh -o ConnectTimeout=$this->connectTimeout $this->userName@$this->hostName -p $this->port -s netconf"); + $this->stream = fopen("expect://ssh -o ConnectTimeout=$this->connectTimeout $this->userName@$this->hostName -p $this->port -s netconf", "rw"); ini_set('expect.timeout', $this->replyTimeout); $flag = true; while ($flag) {