Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- require_once 'netconf/Device.php'; // connect method here is using fopen instead of expect_popen
- $hostname = 'xxxx';
- $username = 'rod';
- $password = 'yyy';
- $port = '22';
- $device = new Device($hostname, $username, $password, $port);
- $device->connect();
- $reply = $device->execute_rpc("get-system-users-information");
- echo $reply->to_string();
- $device->close();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement