Commit Graph
2 Commits
Author SHA1 Message Date
James Bellinger 0cc233ea17 Bug fix: Merging occurs after sorting ACE groups by SecurityIdentifier not before. Added a unit test for this behavior.
Also, fixed the namespace for the ObjectAce unit test.
2012-07-02 23:35:14 -04:00
James Bellinger 6cfe403fda CommonAcl is now essentially fully functional. Its descendants DiscretionaryAcl
and SystemAcl need work, but CommonAcl can be manipulated using RawAcls nicely
now and will test canonicity, merge ACEs, remove meaningless ACEs, sort explicit
deny/allow ACEs by SecurityIdentifier... all the nice things CommonAcl is supposed
to do.

Anyway, this patch... Off the top of my head...
Fixed CommonAce and ObjectAce deserialization/roundtripping with opaque data.
Fixed ObjectAce having the wrong BinaryLength depending on ObjectAceFlags.
GenericAce had two protected static SDDL methods which should be internal.

Added some unit tests for the above. One of the tests compares the binary
output with a blob I produced using the *same unit test* on MS.NET (with a
File.WriteAllText creating the byte array to paste in, naturally), and
happily, it produces identical binary output. Very nice.
2012-07-02 23:19:27 -04:00