01-24-2007 02:58 PM
01-25-2007 05:01 AM
You can use GetCurrentUser function from the Programmer's Toolbox to obtain the name the user is logged in: this function uses SDK GetUserName function.
I am afraid that getting the user permissions will involve heavily digging into system informations, registry and SDK functions: a long way I'm not able to drive you through... ![]()
01-25-2007 11:48 AM
01-26-2007 10:14 AM
01-30-2007 04:10 PM
See also impersonation token, primary token, privilege, process, and security identifier.
-----------------------------
I found the original source code example I once heavily borrowed from for my "shutdown" module, it can be found at the following URL. This one shows how use the access token in order to perform a system shutdown of an NT system. This MSDN article is called "How to Shut Down the System" and is located at: http://msdn2.microsoft.com/en-us/library/aa376871.aspx
Jumper Bones