Skip to content

Instantly share code, notes, and snippets.

@nim4n136
Created March 8, 2021 06:10
Show Gist options
  • Save nim4n136/c5182e3dd170ab54af248db635cfeb97 to your computer and use it in GitHub Desktop.
Save nim4n136/c5182e3dd170ab54af248db635cfeb97 to your computer and use it in GitHub Desktop.
Pysftp sample
import pysftp
credentials = {
"host":'xx',
"username": 'xx',
"password": 'xx'
}
cnopts = pysftp.CnOpts()
cnopts.hostkeys = None
with pysftp.Connection(**credentials, cnopts=cnopts) as conn:
conn.cwd('xx')
conn.get('xx', "xx")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment