• Add a Comment
  • Edit
  • More Actions v
  • Quarantine this Entry

Comments (4)

1 localhost commented Permalink

Windows user who installed Microsoft Powershell (*) can use this single line command:

 
get-acl c:\temp\log.txt | format-list
 
and receive this output:
 
Path : Microsoft.PowerShell.Core\FileSystem::C:\temp\log.txtOwner : NELKEN\db2adminGroup : NELKEN\NoneAccess : BUILTIN\Administrators Allow FullControl NELKEN\db2admin Allow FullControl Everyone Allow ReadAndExecute, Synchronize NT AUTHORITY\SYSTEM Allow FullControl BUILTIN\Users Allow ReadAndExecute, SynchronizeAudit :...
 
----------------------------------(*) Windows PowerShellâ„¢ is a new Windows command-line shell designed especially for system administrators. The shell includes an interactive prompt and a scripting environment that can be used independently or in combination
 
Jan M. Nelken

2 localhost commented Trackback

Thanks for the comment Jan. I was wondering what happened to the "Monad" project. I hope I get time to install and play around with PowerShell soon.

3 localhost commented Trackback

But the result of get-acl is not the same as you would get from GetEffectiveRightsFromAcl. Support for this Win32 API call is missing in .NET as well as in Powershell currently.

4 localhost commented Permalink

I copied the first example and changed the LogonUser() parameter LOGON32_LOGON_INTERACTIVE to NETWORK. It worked when the file exists on my C drive, but when I tried to test the access against a file on a network drive, AccessCheck() returned a "false positive". The only way I was able to determine my access rights was to actually open it. The open failed for security reasons. Is there a way to make it work for networked drives as well?

 
rtsujimoto_consultant@cusa.canon.com

Add a Comment Add a Comment