Skip to content
Memory corruption Write-up Advanced

PuTTY 0.66 fixes security vulnerability

PuTTY versions 0.54 to 0.65 have an integer overflow in the ECH (erase characters) control sequence handling, which can cause memory corruption. An attacker who can insert a crafted escape sequence into the terminal stream could potentially exploit this to corrupt memory.

chiark.greenend.org.uk

Published on chiark.greenend.org.uk

Home | FAQ | Feedback | Licence | Updates | Mirrors | Keys | Links | Team Download: Stable · Snapshot | Docs | Privacy | Changes | Wishlist

The author, on chiark.greenend.org.uk

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely, the integer variable used to store the number of characters to erase is signed and not properly checked for overflow, allowing a very large value to cause out-of-bounds memory access.

Impact

An attacker could potentially corrupt memory, which might be exploitable if they can arrange for a specific value to be near sensitive data.

What the attacker needed

Access to the server you connect to; ability to insert escape sequence before encryption

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

PuTTY is a program for connecting to remote computers. It has a bug in how it handles a special command that tells it to erase characters on screen. If an attacker can send a malicious command, they might be able to mess with the program's memory, which could lead to further problems.

What is Memory corruption?

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.

Similar reports

View all

Same bug class and techniques, clearest first.

Memory corruption

The lesson behind this report.

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.