bug-findutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #13303] find should filter out non-printable characters if outputti


From: Andreas Metzler
Subject: [bug #13303] find should filter out non-printable characters if outputting to tty
Date: Sun, 5 Jun 2005 12:02:59 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.8) Gecko/20050513 Debian/1.7.8-1

URL:
  <http://savannah.gnu.org/bugs/?func=detailitem&item_id=13303>

                 Summary: find should filter out non-printable characters if
outputting to tty
                 Project: findutils
            Submitted by: ametzler
            Submitted on: Son 05.06.2005 um 12:02
                Category: find
                Severity: 3 - Normal
              Item Group: None
                  Status: None
                 Privacy: Public
             Assigned to: None
         Originator Name: Vincent Lefevre
        Originator Email: address@hidden
             Open/Closed: Open
                 Release: 4.2.20
           Fixed Release: None

    _______________________________________________________

Details:

This is http://bugs.debian.org/311384 reported against the Debian bug
tracking system.

----------------------
Vincent Lefevre <address@hidden> writes:
The "find" command should filter out non-printable characters when the output
stream (stdout or stderr) is attached to a terminal. Otherwise escape
sequences may be sent to the terminal, for instance when there are filenames
encoded in UTF-8 and the user has ISO-8859 locales. Also

$ touch "test`tput mc0`"
$ find .

will print some data if your terminal supports printing (e.g. xterm, if this
support hasn't been disabled by setting printerCommand to an empty string).
This is bad for the security/privacy as some malicious user may create such a
filename...
----------------------

Afaict dumping non printable characters to the terminal usually is not wanted
and should not be default.

Posix says:
-print
    The primary shall always evaluate as true; it shall cause 
    the current pathname to be written to standard output.

so by filtering out these characters (e.g by replacing them with
questionmarks or their escapecodes) we would not be following posix to the
letter. But do you want to be _that_ strict?
            cu andreas



    _______________________________________________________

Carbon-Copy List:

CC Address                          | Comment
------------------------------------+-----------------------------
address@hidden    | submitter and BTS




    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?func=detailitem&item_id=13303>

_______________________________________________
  Nachricht geschickt von/durch Savannah
  http://savannah.gnu.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]