getfacl display some characters as escaped octal in username

Bug #195792 reported by Etienne Goyer
2
Affects Status Importance Assigned to Milestone
acl (Debian)
New
Unknown
acl (Ubuntu)
Confirmed
Low
Unassigned

Bug Description

Binary package hint: acl

When a user have various non-standard characters in usernames (such as "é" or "\"), and there are ACL for that user, getfacl display the unusual characters as octal.

While it may not be correct to have these characters in Unix username, the backslash is often found in username when using the winbind NSS backend for passwd. As such, it is a very common use case.

Moreover, ls and other tools from coreutils behave as expected and show the non-standard characters correctly.

Example:

----------------------------------------------------------------------------------------------
ubuntu@test-eg:~/test$ touch test1
ubuntu@test-eg:~/test$ setfacl -m u:CANONICAL\\etienne:rwx test1
ubuntu@test-eg:~/test$ getfacl test1
# file: test1
# owner: ubuntu
# group: ubuntu
user::rw-
user:lp:rwx
user:CANONICAL\134etienne:rwx
group::r-x
mask::rwx
other::r--

ubuntu@test-eg:~/test$ sudo chown CANONICAL\\etienne test1
ubuntu@test-eg:~/test$ ls -l test1
-rw-rwxr--+ 1 CANONICAL\etienne ubuntu 0 2008-02-26 00:17 test1
ubuntu@test-eg:~/test$ touch test2
ubuntu@test-eg:~/test$ setfacl -m u:testé:rwx test2
ubuntu@test-eg:~/test$ getfacl test2
# file: test2
# owner: ubuntu
# group: ubuntu
user::rw-
user:lp:rwx
user:test\303\251:rwx
group::r-x
mask::rwx
other::r--

ubuntu@test-eg:~/test$ sudo chown testé test2
ubuntu@test-eg:~/test$ ls -l test2
-rw-rwxr--+ 1 testé ubuntu 0 2008-02-26 00:17 test2
---------------------------------------------------------------------------------------------------

Note that, in the above example, the backslash have to be escaped with another backslash (ie, "\\") to prevent interpretation by the shell; the username have a single backslash indeed.

Changed in acl:
importance: Undecided → Low
status: New → Confirmed
Changed in acl (Debian):
status: Unknown → New
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.