~x3lectric/ntfs-3g/trunk

Viewing all changes in revision 1201.

  • Committer: Jean-Pierre André
  • Date: 2015-07-14 06:37:01 UTC
  • Revision ID: git-v1:2c11aaa2aa9900f24f09c6903c3b9fdb79e38689
Fixed the range of valid subauthority counts in a SID

ntfs_valid_sid() required that the subauthority count be between 1 and 8
inclusively.  However, Windows permits more than 8 subauthorities as well
as 0 subauthorities:

  - The install.wim file for the latest Windows 10 build contains a file
    whose DACL contains a SID with 10 subauthorities.
    ntfs_set_ntfs_acl() was failing on this file.

  - The IsValidSid() function on Windows returns true for subauthority
    less than or equal to 15, including 0.

There was actually already a another SID validation function that had the
Windows-compatible behavior, so I merged the two together.

Contributed by Eric Biggers

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: