You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.rst
+5-6Lines changed: 5 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -45,7 +45,7 @@ At this time all of the `libssh2`_ API has been implemented up to version ``1.8.
45
45
46
46
Complete example scripts for various operations can be found in the `examples directory`_.
47
47
48
-
In addition, as ``ssh2-python`` is a thin wrapper of ``libssh2`` with Python semantics, its code examples can be ported straight over to Python with only minimal changes.
48
+
In addition, as ``ssh2-python`` is a thin wrapper of ``libssh2`` with Python semantics, `its code examples<https://libssh2.org/examples/>`_ can be ported straight over to Python with only minimal changes.
49
49
50
50
51
51
Library Features
@@ -96,6 +96,8 @@ Connect and get available authentication methods.
96
96
print(session.userauth_list())
97
97
98
98
99
+
Output will vary depending on SSH server configuration. For example:
100
+
99
101
.. code-block:: python
100
102
101
103
['publickey', 'password', 'keyboard-interactive']
@@ -104,7 +106,6 @@ Connect and get available authentication methods.
104
106
Agent Authentication
105
107
------------------------
106
108
107
-
108
109
.. code-block:: python
109
110
110
111
session.agent_auth(user)
@@ -113,7 +114,6 @@ Agent Authentication
113
114
Command Execution
114
115
------------------------
115
116
116
-
117
117
.. code-block:: python
118
118
119
119
channel = session.open_session()
@@ -154,16 +154,15 @@ Public Key Authentication
154
154
.. code-block:: python
155
155
156
156
session.userauth_publickey_fromfile(
157
-
username, 'my_pkey.pub', 'my_pkey', '')
157
+
username, 'private_key_file')
158
158
159
159
160
-
Where ``''`` can be a passphrase.
160
+
Passphrase can be provided with the ``passphrase`` keyword param - see `API documentation <https://ssh2-python.readthedocs.io/en/latest/session.html#ssh2.session.Session.userauth_publickey_fromfile>`_.
0 commit comments