Bug 430621

Summary: debugfs doesn't print selinux values properly
Product: [Fedora] Fedora Reporter: Eric Sandeen <esandeen>
Component: e2fsprogsAssignee: Eric Sandeen <esandeen>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: low    
Version: rawhideCC: kzak, oliver
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: 1.40.7-1 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2008-02-29 16:48:21 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Eric Sandeen 2008-01-29 05:17:54 UTC
Oddity:

debugfs:  stat .
Inode: 2   Type: directory    Mode:  0755   Flags: 0x0   Generation: 0
User:     0   Group:     0   Size: 4096
File ACL: 0    Directory ACL: 0
Links: 23   Blockcount: 8
Fragment:  Address: 0    Number: 0    Size: 0
ctime: 0x479ea01f -- Mon Jan 28 21:40:15 2008
atime: 0x479ea020 -- Mon Jan 28 21:40:16 2008
mtime: 0x479ea01f -- Mon Jan 28 21:40:15 2008
Size of extra inode fields: 28
Extended attributes stored in inode body: 
  selinux = "73 79 73 74 65 6d 5f 75 3a 6f 62 6a 65 63 74 5f 72 3a 72 6f 6f 74
5f 74 3a 73 30 00 " (28)
BLOCKS:
(0):816
TOTAL: 1

# echo -n "system_u:object_r:root_t:s0" | hexdump -C
00000000  73 79 73 74 65 6d 5f 75  3a 6f 62 6a 65 63 74 5f  |system_u:object_|
00000010  72 3a 72 6f 6f 74 5f 74  3a 73 30                 |r:root_t:s0|

looks like getting the null at the end throws "isprint" off.

Comment 1 Eric Sandeen 2008-02-28 19:41:24 UTC
Patch sent & committed upstream:
http://git.kernel.org/?p=fs/ext2/e2fsprogs.git;a=commit;h=290ac0e321e02cbd8041e9775fae3fcb8e23377d

Comment 2 Eric Sandeen 2008-02-29 16:48:21 UTC
On its way to rawhide via e2fsprogs-1.40.7-1