Skip to content

Commit 438fe60

Browse files
committed
Limit REP to 64k. See email with subject line 'Minor iTerm 2 DoS'
1 parent f348f33 commit 438fe60

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sources/VT100Terminal.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2490,7 +2490,7 @@ - (void)reallyExecuteToken:(VT100Token *)token {
24902490
break;
24912491

24922492
case VT100CSI_REP:
2493-
[_delegate terminalRepeatPreviousCharacter:token.csi->p[0]];
2493+
[_delegate terminalRepeatPreviousCharacter:MIN(65535, token.csi->p[0])];
24942494
break;
24952495

24962496
case VT100CSI_DECRQPSR:

0 commit comments

Comments
 (0)