gnachman/iTerm2 — pull request #81 by saitoha (2012-06-02 10:26:26+00:00)
Title: prevent DoS with SU/SD's large repeat counts.

Hi, this is a Quick Fix for prevent DoS (for master branch).

iTerm2 hangs with following escape sequences.

echo -en "\e[2147483647S" // SU
echo -en "\e[2147483647T" // SD

Home similar issues were found:

vte - https://bugzilla.gnome.org/show_bug.cgi?id=676090
mintty - http://code.google.com/p/mintty/issues/detail?id=306
mosh - https://github.com/keithw/mosh/issues/271

Expediently, this patch restricts SU/SD's parameter to 1024.