Skip to content

Commit 747f6c1

Browse files
author
Kolea Plesco
committed
removed hostkey verification
1 parent 387ab6f commit 747f6c1

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

ted_sws/notice_publisher/adapters/sftp_notice_publisher.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,16 @@ def connect(self):
2525
"""Connects to the sftp server and returns the sftp connection object"""
2626

2727
try:
28+
cnopts = pysftp.CnOpts()
29+
# TODO: to be checked/removed when SSL will be setup
30+
cnopts.hostkeys = None
2831
# Get the sftp connection object
2932
self.connection = pysftp.Connection(
3033
host=self.hostname,
3134
username=self.username,
3235
password=self.password,
3336
port=self.port,
37+
cnopts=cnopts
3438
)
3539
except Exception as err:
3640
raise Exception(err)

0 commit comments

Comments
 (0)