Skip to contentSkip to conversation

console_codes(4): Add ESC [ 3 J

PATCH In review Petr Písař 2 participants 4 messages Apr 22, 2011 – Sep 15, 2011 2 messages not in the archive Man-pages: manual pages for Linux -- Sections 2, 3, 4, 5, and 7

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 console_codes(4): Add ESC [ 3 J

Linux is going
(http://git.kernel.org/?p=linux/kernel/git/next/linux-next.git;a=commit;h=f8df13e0a901fe55631fed66562369b4dba40f8b)
to implement \E[3J to allow scrambling content of console including scroll-back buffer (http://thread.gmane.org/gmane.linux.kernel/1125792).

This is useful at terminal lock to disallow attacker to scroll visible window back and to see sensitive data. Other \E[J sequences do not blank history. Terminal reset (\Ec) or DECSRC are not suitable for extension too beacuse they reset font, keyboard locks, unicode mode etc. that are needed after unlocking session.

\E[3J is superset of \E[2J. IOW it clears visible screen too.

---
 man4/console_codes.4 |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
man4/console_codes.4 +2 -0
index 2a806b7..62f2247 100644
@@ -188,6 +188,8 @@ H	CUP	Move cursor to the indicated row, column (origin at 1,1).
 J	ED	Erase display (default: from cursor to end of display).
 		ESC [ 1 J: erase from start to cursor.
 		ESC [ 2 J: erase whole display.
+		ESC [ 3 J: erase whole display including scroll-back
+		buffer.
 K	EL	Erase line (default: from cursor to end of line).
 		ESC [ 1 K: erase from start of line to cursor.
 		ESC [ 2 K: erase whole line.
Signature · 6 lines
1.7.4.4

--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

A message that is not in the archive (sent off-list or not yet received): 1303479685-12475-1-git-send-email-ppisar-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org

#2 lore raw

Petr,

2011/4/22 Petr Písař <[email protected]>:

Quoted 4 lines

Linux is going
(http://git.kernel.org/?p=linux/kernel/git/next/linux-next.git;a=commit;h=f8df13e0a901fe55631fed66562369b4dba40f8b)
to implement \E[3J to allow scrambling content of console including scroll-back buffer (http://thread.gmane.org/gmane.linux.kernel/1125792).

In which kernel version was this patch applied?

Cheers,

Michael

Quoted 30 lines

This is useful at terminal lock to disallow attacker to scroll visible window back and to see sensitive data. Other \E[J sequences do not blank history. Terminal reset (\Ec) or DECSRC are not suitable for extension too beacuse they reset font, keyboard locks, unicode mode etc. that are needed after unlocking session.

\E[3J is superset of \E[2J. IOW it clears visible screen too.

---
 man4/console_codes.4 |    2 ++

 1 files changed, 2 insertions(+), 0 deletions(-)
man4/console_codes.4 +0 -0
index 2a806b7..62f2247 100644
@@ -188,6 +188,8 @@ H   CUP     Move cursor to the indicated row, column (origin at 1,1).

 J      ED      Erase display (default: from cursor to end of display). ESC [ 1 J: erase from start to cursor.
               ESC [ 2 J: erase whole display.
+               ESC [ 3 J: erase whole display including scroll-back
+               buffer.
 K      EL      Erase line (default: from cursor to end of line). ESC [ 1 K: erase from start of line to cursor. ESC [ 2 K: erase whole line.
--
1.7.4.4

Signature · 7 lines
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Author of "The Linux Programming Interface"; http://man7.org/tlpi/
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

A message that is not in the archive (sent off-list or not yet received): CAKgNAkjiMtfAyTD5=5gz_Q1rpG7hikg_1o_L+FQo7GsfiSyhKw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org

author
#4 lore raw
Quoted 9 lines · Michael Kerrisk

2011/4/22 Petr Písař <[email protected]>:

Quoted 4 lines

Linux is going
(http://git.kernel.org/?p=linux/kernel/git/next/linux-next.git;a=commit;h=f8df13e0a901fe55631fed66562369b4dba40f8b)
to implement \E[3J to allow scrambling content of console including scroll-back buffer (http://thread.gmane.org/gmane.linux.kernel/1125792).

In which kernel version was this patch applied?

3.0.

-- Petr

Quoted 30 lines
Quoted 30 lines

This is useful at terminal lock to disallow attacker to scroll visible window back and to see sensitive data. Other \E[J sequences do not blank history. Terminal reset (\Ec) or DECSRC are not suitable for extension too beacuse they reset font, keyboard locks, unicode mode etc. that are needed after unlocking session.

\E[3J is superset of \E[2J. IOW it clears visible screen too.

---
 man4/console_codes.4 |    2 ++

 1 files changed, 2 insertions(+), 0 deletions(-)
man4/console_codes.4 +0 -0
index 2a806b7..62f2247 100644
@@ -188,6 +188,8 @@ H   CUP     Move cursor to the indicated row, column (origin at 1,1).

 J      ED      Erase display (default: from cursor to end of display). ESC [ 1 J: erase from start to cursor.
               ESC [ 2 J: erase whole display.
+               ESC [ 3 J: erase whole display including scroll-back
+               buffer.
 K      EL      Erase line (default: from cursor to end of line). ESC [ 1 K: erase from start of line to cursor. ESC [ 2 K: erase whole line.
--
1.7.4.4

#5 lore raw
In reply to a message not in the archive

Hello Petr,

2011/4/22 Petr Písař <[email protected]>:

Quoted 11 lines

Linux is going
(http://git.kernel.org/?p=linux/kernel/git/next/linux-next.git;a=commit;h=f8df13e0a901fe55631fed66562369b4dba40f8b)
to implement \E[3J to allow scrambling content of console including scroll-back buffer (http://thread.gmane.org/gmane.linux.kernel/1125792).

This is useful at terminal lock to disallow attacker to scroll visible window back and to see sensitive data. Other \E[J sequences do not blank history. Terminal reset (\Ec) or DECSRC are not suitable for extension too beacuse they reset font, keyboard locks, unicode mode etc. that are needed after unlocking session.

Quoted 3 lines

\E[3J is superset of \E[2J. IOW it clears visible screen too.

Thanks. I applied this for man-pages-3.33.

Cheers,

Michael

Quoted 21 lines

---
 man4/console_codes.4 |    2 ++

 1 files changed, 2 insertions(+), 0 deletions(-)
man4/console_codes.4 +0 -0
index 2a806b7..62f2247 100644
@@ -188,6 +188,8 @@ H   CUP     Move cursor to the indicated row, column (origin at 1,1).

 J      ED      Erase display (default: from cursor to end of display). ESC [ 1 J: erase from start to cursor.
               ESC [ 2 J: erase whole display.
+               ESC [ 3 J: erase whole display including scroll-back
+               buffer.
 K      EL      Erase line (default: from cursor to end of line). ESC [ 1 K: erase from start of line to cursor. ESC [ 2 K: erase whole line.
--
1.7.4.4

Signature · 7 lines
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Author of "The Linux Programming Interface"; http://man7.org/tlpi/
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html