---
schema_version: "1"
id: 32b437adb4bca3f23b2df83ca0ddb09fa188aced3bb9d2d6dded897944c29c93
title: Upgrade and Migrate SFTP Connector to Version 2.x
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/sftp-connector/latest/sftp-connector-upgrade-guide.md
canonical_url: https://docs.mulesoft.com/sftp-connector/latest/sftp-connector-upgrade-guide
source_site: docs.mulesoft.com
content_type: documentation
content_hash: 2004b270de577c15ece48f8717685349bd7febf036027b5ac41a4962a043f87f
description: MuleSoft Documentation Site
release: "2.7"
latest: true
---
---
product: SFTP Connector
version: 2.7
is-latest-version: true
---

# Upgrade and Migrate SFTP Connector to Version 2.x

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

Upgrade Anypoint Connector for SFTP (SFTP Connector) to version 2.x.x.

## Supported Upgrade Paths

<table><colgroup><col> <col></colgroup><thead><tr><th>From Version</th><th>To Version</th></tr></thead><tbody><tr><td><div><div><p>1.6.0</p></div></div></td><td><div><div><p>2.x.x</p></div></div></td></tr></tbody></table>

## Changes in This Release

This release contains the following changes:

- The connector has a new custom [**write strategy**](https://docs.mulesoft.com/sftp-connector/latest/sftp-write#write-strategy) field that enables
  you to configure the strategy to write a file.

- The system property `mule.sftp.useHomeDirectory` was removed. SFTP Connector now uses the default
  home directory.

- SFTP Connector 2.x.x no longer supports the `jcraft library`. The connector now uses the
  `apache mina sshd` library.

- The **List** operation no longer fetches the content of each file. Now, the payload of each list
  item contains the complete path to the found file or directory.

- The SFTP **Regular Size** file attribute is renamed to **Regular File** because its behavior is
  not related to size. The file attribute value can be a file (`true`) or a directory (`false`).

- SFTP Connector 2.x.x does not support ciphers `3des-ctr` and `arcfour`. For more information,
  refer to [Supported Ciphers project](#supported-ciphers).

- The SFTP proxy protocol works only with HTTP and SOCKS5.

- SFTP Connector no longer uses `javax.activation` to resolve the media types of the files. The
  connector now uses `Apache Tika`, which can result in different media file interpretations.

- The connector changed the classes to manage the date from `LocalDateTime` to `ZonedDateTime`.

- The deprecated **Encoding** parameter in the configuration and **Write** operation is removed. The
  connector uses the Mule’s default encoding.

## Upgrade Prerequisites

Before you perform the upgrade, you must complete the following:

- Create a backup of your files, data, and configurations in case you need to restore to them.

## Upgrade Steps

Follow these steps to perform the upgrade:

1.  In Anypoint Studio, create a Mule project.

2.  In **Mule Palette**, click **Search in Exchange**.

3.  In **Add Dependencies to Project**, enter `SFTP` in the search field.

4.  In **Available modules**, select **SFTP Connector** and click **Add**.

5.  Click **Finish**.

6.  Verify that the SFTP Connector `mule-sftp-connector` version is `2.x.x` in the `pom.xml` file in
    the Mule project.

Studio upgrades the connector automatically.

## Post Upgrade Steps

After you install the latest version of the connector, follow these steps to complete the upgrade:

### Verify the Upgrade

After you install the latest version of the connector, verify the upgrade:

1.  In Studio, verify that there are no errors in the **Problems** or **Console** views.

2.  Verify that there are no problems in the project `pom.xml` file.

3.  Test the connection to verify that the operations work.

## Supported Ciphers

The Apache Mina SSHD library does not support ciphers `3des-ctr` and `arcfour`. Additionally, the
library introduces `aes128-gcm`, `aes256-gcm`, and `cc20p1305_openssh` as alternatives.

> [!NOTE] For the current version of the SFTP Connector, you must stick to the Apache Mina default
> options. Refer to the
> [Apache Mina Supported Standards](https://github.com/apache/mina-sshd/blob/sshd-2.12.1/docs/standards.md#implementedavailable-support).

For details, review the following table:

<table><colgroup><col> <col></colgroup><thead><tr><th>JSCH - SFTP Connector 1.6</th><th><a href="https://github.com/apache/mina-sshd/blob/sshd-2.9.2/sshd-common/src/main/java/org/apache/sshd/common/cipher/BuiltinCiphers.java">MINA SSHD</a> - SFTP Connector 2.0</th></tr></thead><tbody><tr><td><div><div><p><code>blowfish-cbc</code></p></div></div></td><td><div><div><p><code>blowfish-cbc</code> (Deprecated)</p></div></div></td></tr><tr><td><div><div><p><code>3des-cbc</code></p></div></div></td><td><div><div><p><code>3des-cbc</code> (Deprecated)</p></div></div></td></tr><tr><td><div><div><p><code>3des-ctr</code></p></div></div></td><td><div><div><p>Not supported.</p></div></div></td></tr><tr><td><div><div><p><code>aes128-cbc</code></p></div></div></td><td><div><div><p><code>aes128-cbc</code></p></div></div></td></tr><tr><td><div><div><p><code>aes128-ctr</code></p></div></div></td><td><div><div><p><code>aes128-ctr</code></p></div></div></td></tr><tr><td><div><div><p>Not supported.</p></div></div></td><td><div><div><p><code>aes128-gcm</code></p></div></div></td></tr><tr><td><div><div><p><code>aes192-cbc</code></p></div></div></td><td><div><div><p><code>aes192-cbc</code></p></div></div></td></tr><tr><td><div><div><p><code>aes192-ctr</code></p></div></div></td><td><div><div><p><code>aes192-ctr</code></p></div></div></td></tr><tr><td><div><div><p><code>aes256-cbc</code></p></div></div></td><td><div><div><p><code>aes256-cbc</code></p></div></div></td></tr><tr><td><div><div><p><code>aes256-ctr</code></p></div></div></td><td><div><div><p><code>aes256-ctr</code></p></div></div></td></tr><tr><td><div><div><p>Not supported.</p></div></div></td><td><div><div><p><code>aes256-gcm</code></p></div></div></td></tr><tr><td><div><div><p><code>arcfour</code></p></div></div></td><td><div><div><p>Not supported.</p></div></div></td></tr><tr><td><div><div><p><code>arcfour128</code></p></div></div></td><td><div><div><p><code>arcfour128</code> (Deprecated)</p></div></div></td></tr><tr><td><div><div><p><code>arcfour256</code></p></div></div></td><td><div><div><p><code>arcfour256</code> (Deprecated)</p></div></div></td></tr><tr><td><div><div><p>Not supported.</p></div></div></td><td><div><div><p><code>cc20p1305_openssh</code></p></div></div></td></tr></tbody></table>

## Other Supported Cryptographic Entities

<table><colgroup><col> <col> <col></colgroup><thead><tr><th>Kex Algorithms</th><th>Host Key Algorithms</th><th>MACs</th></tr></thead><tbody><tr><td><p><code>curve25519-sha256</code>*</p></td><td><p><code>ecdsa-sha2-nistp256-cert-v01@openssh.com</code></p></td><td><p><code>hmac-sha2-256-etm@openssh.com</code></p></td></tr><tr><td><p><code>curve25519-sha256@libssh.org</code>*</p></td><td><p><code>ecdsa-sha2-nistp384-cert-v01@openssh.com</code></p></td><td><p><code>hmac-sha2-512-etm@openssh.com</code></p></td></tr><tr><td><p><code>curve448-sha512</code>*</p></td><td><p><code>ecdsa-sha2-nistp521-cert-v01@openssh.com</code></p></td><td><p><code>hmac-sha1-etm@openssh.com</code></p></td></tr><tr><td><p><code>ecdh-sha2-nistp521</code></p></td><td><p><code>ssh-ed25519-cert-v01@openssh.com</code></p></td><td><p><code>hmac-sha2-256</code></p></td></tr><tr><td><p><code>ecdh-sha2-nistp384</code></p></td><td><p><code>rsa-sha2-512-cert-v01@openssh.com</code></p></td><td><p><code>hmac-sha2-512</code></p></td></tr><tr><td><p><code>ecdh-sha2-nistp256</code></p></td><td><p><code>rsa-sha2-256-cert-v01@openssh.com</code></p></td><td><p><code>hmac-sha1</code></p></td></tr><tr><td><p><code>diffie-hellman-group-exchange-sha256</code></p></td><td><p><code>ecdsa-sha2-nistp256</code></p></td><td><p><code>hmac-md5</code> (Deprecated)</p></td></tr><tr><td><p><code>diffie-hellman-group18-sha512</code></p></td><td><p><code>ecdsa-sha2-nistp384</code></p></td><td><p><code>hmac-md5-96</code> (Deprecated)</p></td></tr><tr><td><p><code>diffie-hellman-group17-sha512</code></p></td><td><p><code>ecdsa-sha2-nistp521</code></p></td><td><p><code>hmac-sha1-96</code> (Deprecated)</p></td></tr><tr><td><p><code>diffie-hellman-group16-sha512</code></p></td><td><p><code>ssh-ed25519</code>**</p></td><td></td></tr><tr><td><p><code>diffie-hellman-group15-sha512</code></p></td><td><p><code>sk-ecdsa-sha2-nistp256@openssh.com</code></p></td><td></td></tr><tr><td><p><code>diffie-hellman-group14-sha256</code></p></td><td><p><code>sk-ssh-ed25519@openssh.com</code>**</p></td><td></td></tr><tr><td><p><code>diffie-hellman-group1-sha1</code> (Deprecated)</p></td><td><p><code>rsa-sha2-512</code></p></td><td></td></tr><tr><td><p><code>diffie-hellman-group14-sha1</code> (Deprecated)</p></td><td><p><code>rsa-sha2-256</code></p></td><td></td></tr><tr><td><p><code>diffie-hellman-group-exchange-sha1</code> (Deprecated)</p></td><td><p><code>ssh-rsa</code></p></td><td></td></tr><tr><td></td><td><p><code>ssh-dss</code> (Deprecated)</p></td><td></td></tr><tr><td></td><td><p><code>ssh-dss-cert-v01@openssh.com</code> (Deprecated)</p></td><td></td></tr><tr><td></td><td><p><code>ssh-rsa-cert-v01@openssh.com</code> (Deprecated)</p></td><td></td></tr></tbody></table>

`*` These algorithms require Bouncy Castle on Java versions before Java 11.

`**` These algorithms require externally EdDSA (Edwards-curve Digital Signature Algorithm) library.

## Troubleshooting

### Reverting the Upgrade

If you need to revert to the previous version of SFTP Connector, go to Anypoint Studio and in the
project’s `pom.xml` file, change the `mule-sftp-connector` dependency version 2.x.x to the previous
version.

### Override SSH Connection Security Configuration

If you face SSH connection issues due to unsupported ciphers, macs, hostKeyAlgorithms or
kexAlgorithms, then change the priority or enable deprecated ciphers and algorithms forcefully.
Although using this method may introduce additional risk. Refer to
[Configure Security Parameters of SSH Connection](https://docs.mulesoft.com/sftp-connector/latest/sftp-security-configuration-override) and
[SFTP Connector Reference](https://docs.mulesoft.com/sftp-connector/latest/sftp-documentation).

### Override Standard Write Strategy

If your **File Write** operation overrides instead of appending when using the `APPEND` mode, use
the `CUSTOM` write strategy along with the `CUSTOM_APPEND` mode only as it isn’t applicable to the
other modes. With this strategy, you can manually specify the offset for the server to write the
file in `APPEND` mode, particularly only for older SFTP servers that don’t directly support write
modes. Use this strategy only if the `STANDARD` strategy results in errors during file writing in
`APPEND` mode and doesn’t offer concurrency. Additionally, you can adjust the buffer size in the
**Buffer Size for Write Strategy** field.

## See Also

- [Introduction to Anypoint Connectors](https://docs.mulesoft.com/connectors/introduction/introduction-to-anypoint-connectors)

- [Salesforce Help](https://help.salesforce.com)
