Chapter 47. How to Program ACLs

No book on windows security programming would be complete without showing you how to programmatically read, write, or modify an ACL. But frankly, before you run off and write lots of code to do this, consider whether it's really the right thing to do. Security policy is normally controlled by administrators, and programs usually can't make these decisions—even installation programs. Maybe what you really need is a graphical editor to allow an administrator to specify an ACL, and then you can simply persist that ACL somewhere until your program needs it. I like that idea a lot better than having people hardcode ACLs in their code!

To that end, I've uploaded some code to my Web site that I've been carrying around with ...

Get The .NET Developer's Guide to Windows Security now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.