CVE-2026-54886: SSH SFTP server denial of service via extended channel data infinite loop

Published Jul 2, 2026
·
Updated

Summary

Loop with Unreachable Exit Condition ('Infinite Loop') vulnerability in Erlang OTP ssh (sshsftpd module) allows an authenticated SFTP user to render an SFTP channel permanently unresponsive.

The handledata/4 function in sshsftpd contains a catch-all clause that accepts channel data of any type. When channel data with a non-zero type code (SSHMSGCHANNELEXTENDEDDATA) arrives with an empty pending buffer and a payload at or below the SFTP packet size limit, the clause tail-calls itself with identical arguments, creating an infinite loop.

The SFTP protocol operates exclusively on normal channel data (type 0). Extended data (non-zero type) is meaningless for SFTP and is never sent by conforming clients. However, the SSH protocol permits any channel participant to send extended data on an open channel, so an authenticated SFTP client can trigger the loop by sending SSHMSGCHANNELEXTENDEDDATA with any datatypecode and any non-empty payload at or below the size limit.

The targeted sshsftpd process enters an infinite tail-recursive loop. It never processes another message, its message queue grows without bound, and it can only be stopped by killing the process. BEAM's reduction-based scheduler preemption continues to function, so other processes on the node are not starved, but each stuck channel process consumes its full CPU time share continuously and accumulates unbounded message queue memory. Opening many channels amplifies the CPU and memory impact.

Erlang/OTP SSH configurations using the default maxchannels setting (infinity) allow an authenticated user to open unlimited channels per connection, amplifying the attack without requiring multiple TCP connections or authentications.

No file contents, credentials, or write access are obtainable through this issue. The impact is limited to denial of service on targeted SFTP channels, with secondary CPU degradation and memory growth.

This vulnerability is associated with program file lib/ssh/src/sshsftpd.erl and program routine sshsftpd:handledata/4.

This issue affects OTP from OTP 17.0 before OTP 27.3.4.14, OTP 28.5.0.3, and OTP 29.0.3, corresponding to ssh from 3.0.1 before 5.2.11.9, 5.5.2.2, and 6.0.2. Whether OTP before OTP 17.0, corresponding to ssh before 3.0.1, is affected is unknown.

Workarounds

Set the maxchannels daemon option to a finite value (e.g., {maxchannels, 10}) to limit the number of channels an attacker can open per connection. Set the maxsessions daemon option to limit total concurrent SSH connections to the daemon. Use external process monitoring to detect and kill sshsftpd processes with abnormally high reduction counts and growing message queues. Ensure that the SFTP server port is not reachable from untrusted machines.

Other sources

Loop with Unreachable Exit Condition ('Infinite Loop') vulnerability in Erlang OTP ssh (sshsftpd module) allows an authenticated SFTP user to render an SFTP channel permanently unresponsive.

The handledata/4 function in sshsftpd contains a catch-all clause that accepts channel data of any type. When channel data with a non-zero type code (SSHMSGCHANNELEXTENDEDDATA) arrives with an empty pending buffer and a payload at or below the SFTP packet size limit, the clause tail-calls itself with identical arguments, creating an infinite loop.

The SFTP protocol operates exclusively on normal channel data (type 0). Extended data (non-zero type) is meaningless for SFTP and is never sent by conforming clients. However, the SSH protocol permits any channel participant to send extended data on an open channel, so an authenticated SFTP client can trigger the loop by sending SSHMSGCHANNELEXTENDEDDATA with any datatypecode and any non-empty payload at or below the size limit.

The targeted sshsftpd process enters an infinite tail-recursive loop. It never processes another message, its message queue grows without bound, and it can only be stopped by killing the process. BEAM's reduction-based scheduler preemption continues to function, so other processes on the node are not starved, but each stuck channel process consumes its full CPU time share continuously and accumulates unbounded message queue memory. Opening many channels amplifies the CPU and memory impact.

Erlang/OTP SSH configurations using the default maxchannels setting (infinity) allow an authenticated user to open unlimited channels per connection, amplifying the attack without requiring multiple TCP connections or authentications.

No file contents, credentials, or write access are obtainable through this issue. The impact is limited to denial of service on targeted SFTP channels, with secondary CPU degradation and memory growth.

This vulnerability is associated with program file lib/ssh/src/sshsftpd.erl and program routine sshsftpd:handledata/4.

This issue affects OTP from OTP 17.0 before OTP 27.3.4.14, OTP 28.5.0.3, and OTP 29.0.3, corresponding to ssh from 3.0.1 before 5.2.11.9, 5.5.2.2, and 6.0.2. Whether OTP before OTP 17.0, corresponding to ssh before 3.0.1, is affected is unknown.

— MITRE

Loop with Unreachable Exit Condition ('Infinite Loop') vulnerability in Erlang OTP ssh (sshsftpd module) allows an authenticated SFTP user to render an SFTP channel permanently unresponsive.

The handledata/4 function in sshsftpd contains a catch-all clause that accepts channel data of any type. When channel data with a non-zero type code (SSHMSGCHANNELEXTENDEDDATA) arrives with an empty pending buffer and a payload at or below the SFTP packet size limit, the clause tail-calls itself with identical arguments, creating an infinite loop.

The SFTP protocol operates exclusively on normal channel data (type 0). Extended data (non-zero type) is meaningless for SFTP and is never sent by conforming clients. However, the SSH protocol permits any channel participant to send extended data on an open channel, so an authenticated SFTP client can trigger the loop by sending SSHMSGCHANNELEXTENDEDDATA with any datatypecode and any non-empty payload at or below the size limit.

The targeted sshsftpd process enters an infinite tail-recursive loop. It never processes another message, its message queue grows without bound, and it can only be stopped by killing the process. BEAM's reduction-based scheduler preemption continues to function, so other processes on the node are not starved, but each stuck channel process consumes its full CPU time share continuously and accumulates unbounded message queue memory. Opening many channels amplifies the CPU and memory impact.

Erlang/OTP SSH configurations using the default maxchannels setting (infinity) allow an authenticated user to open unlimited channels per connection, amplifying the attack without requiring multiple TCP connections or authentications.

No file contents, credentials, or write access are obtainable through this issue. The impact is limited to denial of service on targeted SFTP channels, with secondary CPU degradation and memory growth.

This vulnerability is associated with program file lib/ssh/src/sshsftpd.erl and program routine sshsftpd:handledata/4.

This issue affects OTP from OTP 17.0 before OTP 29.0.3, OTP 28.5.0.3 and OTP 27.3.4.14, corresponding to ssh from 3.0.1 before 6.0.2, 5.5.2.2 and 5.2.11.9.

— NVD

Loop with Unreachable Exit Condition ('Infinite Loop') vulnerability in Erlang OTP ssh (sshsftpd module) allows an authenticated SFTP user to render an SFTP channel permanently unresponsive.

The handledata/4 function in sshsftpd contains a catch-all clause that accepts channel data of any type. When channel data with a non-zero type code (SSHMSGCHANNELEXTENDEDDATA) arrives with an empty pending buffer and a payload at or below the SFTP packet size limit, the clause tail-calls itself with identical arguments, creating an infinite loop.

The SFTP protocol operates exclusively on normal channel data (type 0). Extended data (non-zero type) is meaningless for SFTP and is never sent by conforming clients. However, the SSH protocol permits any channel participant to send extended data on an open channel, so an authenticated SFTP client can trigger the loop by sending SSHMSGCHANNELEXTENDEDDATA with any datatypecode and any non-empty payload at or below the size limit.

The targeted sshsftpd process enters an infinite tail-recursive loop. It never processes another message, its message queue grows without bound, and it can only be stopped by killing the process. BEAM's reduction-based scheduler preemption continues to function, so other processes on the node are not starved, but each stuck channel process consumes its full CPU time share continuously and accumulates unbounded message queue memory. Opening many channels amplifies the CPU and memory impact.

Erlang/OTP SSH configurations using the default maxchannels setting (infinity) allow an authenticated user to open unlimited channels per connection, amplifying the attack without requiring multiple TCP connections or authentications.

No file contents, credentials, or write access are obtainable through this issue. The impact is limited to denial of service on targeted SFTP channels, with secondary CPU degradation and memory growth.

This vulnerability is associated with program file lib/ssh/src/sshsftpd.erl and program routine sshsftpd:handledata/4.

This issue affects OTP from OTP 17.0 until OTP 29.0.3, 28.5.0.3, and 27.3.4.14 corresponding to ssh from 3.0.1 until 6.0.2, 5.5.2.2, and 5.2.11.9.

— Red Hat

SSH SFTP server denial of service via extended channel data infinite loop

— Microsoft

Affected Software

21 affected componentsFixes available
Erlang Solutions Erlang/OTP>17.0<=29.0.3, =28.5.0.3, =27.3.4.14
Erlang Solutions OTP SSH>3.0.1<=6.0.2, =5.5.2.2, =5.2.11.9
Microsoft azl3 erlang 26.2.5.21-2<26.2.5.21-3
26.2.5.21-3
Erlang Erlang\/otp>=17.0<27.3.4.14
Erlang Erlang\/otp>=28.0<28.5.0.3
Erlang Erlang\/otp>=29.0<29.0.3
Erlang Erlang\/ssh>=3.0.1<5.2.11.9
Erlang Erlang\/ssh>=5.3<5.5.2.2
Erlang Erlang\/ssh>=6.0<6.0.2
ubuntu/erlang<1:16.b.3-dfsg-1ubuntu2.2+esm3
1:16.b.3-dfsg-1ubuntu2.2+esm3
ubuntu/erlang<1:18.3-dfsg-1ubuntu3.1+esm4
1:18.3-dfsg-1ubuntu3.1+esm4
ubuntu/erlang<1:20.2.2+dfsg-1ubuntu2+esm4
1:20.2.2+dfsg-1ubuntu2+esm4
ubuntu/erlang<1:22.2.7+dfsg-1ubuntu0.5+esm3
1:22.2.7+dfsg-1ubuntu0.5+esm3
ubuntu/erlang<1:24.2.1+dfsg-1ubuntu0.8
1:24.2.1+dfsg-1ubuntu0.8
ubuntu/erlang<1:25.3.2.8+dfsg-1ubuntu4.8
1:25.3.2.8+dfsg-1ubuntu4.8
ubuntu/erlang*
ubuntu/erlang<1:27.3.4.6+dfsg-1ubuntu0.2
1:27.3.4.6+dfsg-1ubuntu0.2
debian/erlang*
debian/erlang<1:27.3.4.1+dfsg-1+deb13u3
1:27.3.4.1+dfsg-1+deb13u3
debian/erlang<1:29.0.3+dfsg-1
1:29.0.3+dfsg-1
debian/erlang<=1:25.2.3+dfsg-1+deb12u4, <=1:25.2.3+dfsg-1+deb12u1
1:27.3.4.1+dfsg-1+deb13u31:29.0.3+dfsg-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 26.2.5.21-3
  2. Upgrade

    Upgrade to a fixed release to a version that resolves this vulnerability.

    Fixed in 26.2.5.21-4
  3. Upgrade

    Upgrade ubuntu/erlang to a version that resolves this vulnerability.

    Fixed in 1:16.b.3-dfsg-1ubuntu2.2+esm3
  4. Upgrade

    Upgrade ubuntu/erlang to a version that resolves this vulnerability.

    Fixed in 1:18.3-dfsg-1ubuntu3.1+esm4
  5. Upgrade

    Upgrade ubuntu/erlang to a version that resolves this vulnerability.

    Fixed in 1:20.2.2+dfsg-1ubuntu2+esm4
  6. Upgrade

    Upgrade ubuntu/erlang to a version that resolves this vulnerability.

    Fixed in 1:22.2.7+dfsg-1ubuntu0.5+esm3
  7. Upgrade

    Upgrade ubuntu/erlang to a version that resolves this vulnerability.

    Fixed in 1:24.2.1+dfsg-1ubuntu0.8
  8. Upgrade

    Upgrade ubuntu/erlang to a version that resolves this vulnerability.

    Fixed in 1:25.3.2.8+dfsg-1ubuntu4.8
  9. Upgrade

    Upgrade ubuntu/erlang to a version that resolves this vulnerability.

    Fixed in 1:27.3.4.6+dfsg-1ubuntu0.2
  10. Upgrade

    Upgrade debian/erlang to a version that resolves this vulnerability.

    Fixed in 1:27.3.4.1+dfsg-1+deb13u3
  11. Upgrade

    Upgrade debian/erlang to a version that resolves this vulnerability.

    Fixed in 1:29.0.3+dfsg-1
  12. Upgrade

    Upgrade debian/erlang to a version that resolves this vulnerability.

    Fixed in 1:27.3.4.1+dfsg-1+deb13u3Fixed in 1:29.0.3+dfsg-1
  13. Upgrade

    Upgrade Erlang/OTP to a version that resolves this vulnerability.

    Fixed in 27.3.4.14
  14. Upgrade

    Upgrade Erlang/OTP to a version that resolves this vulnerability.

    Fixed in 28.5.0.3
  15. Upgrade

    Upgrade Erlang/OTP to a version that resolves this vulnerability.

    Fixed in 29.0.3
  16. Configuration

    Set max_channels to a finite value; 10 is an example given in the material.

    Erlang/OTP SSH daemon max_channels = 10
  17. Configuration

    Set max_sessions to limit the total number of concurrent SSH connections to the daemon.

    Erlang/OTP SSH daemon max_sessions
  18. Compensating control

    Ensure the SFTP server port is not reachable from untrusted machines.

  19. Compensating control

    Use external process monitoring to detect and kill ssh_sftpd processes with abnormally high reduction counts and growing message queues.

Event History

Jul 2, 2026
CVE Published
via MITRE·04:06 PM
Data Sourced
via MITRE·04:06 PM
DescriptionWeakness
Data Sourced
via OSV·04:06 PM
DescriptionSeverityWeakness
Data Sourced
via Red Hat·05:02 PM
DescriptionSeverityAffected Software
Data Sourced
via NVD·05:17 PM
DescriptionSeverityWeakness
Jul 7, 2026
Data Sourced
via Microsoft·08:01 AM
DescriptionSeverityWeaknessAffected Software
Data Sourced
via NVD·02:53 PM
RemedyAffected Software
Updated
via NVD·02:53 PM
Severity
Jul 24, 2026
Updated
via MITRE·02:14 PM
Description
Updated
via NVD·03:18 PM
Description
Nov 11, 2026
Updated
via MITRE·06:55 PM
Description
Updated
via NVD·07:17 PM
Description
Nov 18, 2026
Data Sourced
via OSV·02:19 PM
Affected Software

Parent advisories

This vulnerability appears in the following advisories.

Frequently Asked Questions

1

What is the severity of CVE-2026-54886?

CVE-2026-54886 has a risk score of 32, indicating a moderate severity level.

2

How do I fix CVE-2026-54886?

To mitigate CVE-2026-54886, it is recommended to update to the latest version of Erlang/OTP that includes a patch for the vulnerability.

3

What components are affected by CVE-2026-54886?

CVE-2026-54886 affects the ssh_sftpd module in the Erlang/OTP SSH implementation.

4

What type of attack does CVE-2026-54886 facilitate?

CVE-2026-54886 allows an authenticated SFTP user to exploit the vulnerability to create a denial of service condition.

5

Is authentication required to exploit CVE-2026-54886?

Yes, an attacker must be an authenticated SFTP user to exploit the infinite loop vulnerability in CVE-2026-54886.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203