Skip to content

Handling Host Key Change #614

@Clifra-Jones

Description

@Clifra-Jones

We interact with one of out vendors SFTP servers to run schedule jobs that retrieve files. The problem we are running into is that they will do things that cause the host key to change. We are using the -AcceptKey parameter on New-SFTPSession and that works well on the initial connection to the server. What happens is when they make a change and the server has a new host key the connection fails until I remove the old host entry from hosts,json.

I know that this is probably not the best approach re: security but is there any way to accept the new key and overwrite the old host entry? They never tell us when this happens and it causes critical management reporting to fail.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions