After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 794653 - Filter out backspace when pasting
Filter out backspace when pasting
Status: RESOLVED FIXED
Product: vte
Classification: Core
Component: general
git master
Other Linux
: Normal enhancement
: ---
Assigned To: VTE Maintainers
VTE Maintainers
Depends on:
Blocks:
 
 
Reported: 2018-03-24 13:02 UTC by Egmont Koblinger
Modified: 2018-04-09 08:56 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Egmont Koblinger 2018-03-24 13:02:40 UTC
Continuing bug 753197, shouldn't we also filter out BS and DEL?

See also https://unix.stackexchange.com/questions/429897/why-does-linux-allow-backspaces-when-pasting-text-into-a-shell – seems to me there was no use case brought up for allowing these chars.
Comment 1 Ting-Wei Lan 2018-03-24 17:18:22 UTC
I believe there is at least one valid use case. Pasting control characters is an easy way to save time on doing repetitive tasks. You can put all command keys you want to send to a program in a text file and paste them to the terminal.

Please see https://bugzilla.gnome.org/show_bug.cgi?id=753197#c9.

I agree that we should filter all ASCII control characters except for tabs and newlines by default for security reasons, but I think we should also provide an option for users who really want to paste control characters to disable the filter. xterm has 'AllowPasteControls', but vte doesn't seem to have an equivalent option.

This is not a hypothetical use case. The reason that I left a comment in bug 753197 was that I suddenly found that I could not paste a colored article to a BBS site. I can imagine that pasting BS and DEL is still useful for people who want to delete a lot of things managed by TUI programs.
Comment 2 Christian Persch 2018-03-28 21:50:01 UTC
We should include BS and DEL, yes.