Advertisement
Guest User

Untitled

a guest
Aug 29th, 2016
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2. $connection = ssh2_connect('мой ip', 22);
  3. ssh2_auth_password($connection, 'логин', 'пароль');
  4. $stream=ssh2_exec($connection, 'ifconfig' );
  5. stream_set_blocking($stream, true);
  6. echo stream_get_contents($stream);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement