Repository navigation
SMB: enumerate the ACL of each share (which principals can access the share) #1404
Replies: 3 comments 7 replies
|
Hi and thanks for the idea, but this was already implemented with #1138 |
|
Yeah, I like that approach a lot better than a standalone command. A I dug into what's already there, and some of it we can reuse, some not really:
For reading the actual ACL, I grab the share level SD via One thing I wanted to check with you before opening the PR: do you want the ACLs stored in the DB, or is enriching the |
Uh oh!
There was an error while loading. Please reload this page.
Right now
--sharesreports READ/WRITE for the account you're authenticating with. I'd like to also enumerate the share's ACL itself, meaning which principals are granted access to the share, independently of the current user.To be clear, this is different from #157. That one is about the NTFS ACLs of the files inside a share (per file, recursively). This is about the permissions on the share object itself.
What I have working:
--share-aclflag that reads the share level security descriptor (NetrShareGetInfolevel 502, needs admin) and falls back to the NTFS SD of the share root (READ_CONTROL, works with any account that can reach the share)--sharesshare_aclstable and available innxcdb(ashare_aclscommand plusexport), existing databases pick up the new table automaticallyA couple of questions before a PR:
--share-aclflag, or fold it into--shares?Can open the PR once the approach looks good. For transparency, the code was written with AI help and I reviewed and tested all of it myself.
All reactions