17.5 Opening a Command Window with Admin Privileges Using MakeMeAdmin.cmd
Developing software as an Administrator, or running daily as one, is a serious security risk. Additionally, it may cause you to miss privilege-level-related issues in your software until late in the development cycle or, worse yet, after the software’s shipped.
However, if you always run as a regular user, you’re unable to do the occasional tasks that do require administrative privileges, such as working with the IIS management snap-in, setting object permissions, or starting/stopping services. You should do the bulk of your work in the basic user security context, but you can’t completely sacrifice productivity by forcing yourself to log into a new account each time you need to do an administrative task.
Aaron Margosis, author of PrivBar and a member of Microsoft’s .NET Security team, has come up with a great tool to help you solve this problem. MakeMeAdmin.cmd spawns a command prompt that runs under your normal user account, but in a completely new login session in which your account has been added to the local system’s Administrators group.
| |
|---|---|
Tool | MakeMeAdmin.cmd |
Version covered | None given |
Home page | http://blogs.msdn.com/aaron_margosis/archive/2004/07/24/193721.aspx |
Power Tools page | |
Summary | Provides access to a command window with Admin privileges |
License ... | |
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access
