<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Wayne Zimmerman&#039;s Blog &#187; runas</title>
	<atom:link href="http://www.waynezim.com/tag/runas/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.waynezim.com</link>
	<description>My World of Tech, Life and Anything Else</description>
	<lastBuildDate>Fri, 10 Feb 2012 00:13:16 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Allow User To Run Applicaton as Administrator Without a Password</title>
		<link>http://www.waynezim.com/2009/09/allow-user-to-run-applicaton-as-administrator-without-a-password/</link>
		<comments>http://www.waynezim.com/2009/09/allow-user-to-run-applicaton-as-administrator-without-a-password/#comments</comments>
		<pubDate>Tue, 08 Sep 2009 19:26:40 +0000</pubDate>
		<dc:creator>Wayne Zimmerman</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[administrator]]></category>
		<category><![CDATA[Computer]]></category>
		<category><![CDATA[password]]></category>
		<category><![CDATA[runas]]></category>
		<category><![CDATA[VB.NET]]></category>

		<guid isPermaLink="false">http://www.waynezim.com/?p=465</guid>
		<description><![CDATA[A few days ago I came across a software application that just wouldn&#8217;t execute correctly without the user being an administrator on the computer. Since all of my users run as basic / limited users they were unable to use program. After contacting the vendor and looking for all type of rights that we could [...]]]></description>
			<content:encoded><![CDATA[<p>A few days ago I came across a software application that just wouldn&#8217;t execute correctly without the user being an administrator on the computer. Since all of my users run as basic / limited users they were unable to use program. After contacting the vendor and looking for all type of rights that we could grant the user so the could execute the program properly we were unable to fix it without making the user an administrator. So rather than making them an administrator or giving them the administrator password I made a little application that calls the other application as a run as but has the administrator credentials complied in. I realize that you can probably decompile the application and get the password, but for many users that is too much work, or they lack the expertise, so I view this as a small security issue. To further protect the account I made one that only exists on that computer. Below is the code that you can use to build a similar application it is only a few lines but it can solve a headache and keep a password relatively secure.</p>
<p>This is a VB.NET application<br />This application will produce an error if it is unable to login as that account or if the target program cannot be found.</p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p465code2'); return false;">View Code</a> VB</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p4652"><td class="code" id="p465code2"><pre class="vb" style="font-family:monospace;"><span style="color: #000080;">Public</span> Class Form1
    <span style="color: #000080;">Private</span> <span style="color: #000080;">Sub</span> Form1_Load(<span style="color: #000080;">ByVal</span> sender <span style="color: #000080;">As</span> System.<span style="color: #000080;">Object</span>, <span style="color: #000080;">ByVal</span> e <span style="color: #000080;">As</span> System.EventArgs) Handles MyBase.Load
        <span style="color: #000080;">Dim</span> DomainName <span style="color: #000080;">As</span> <span style="color: #000080;">String</span>
        <span style="color: #000080;">Dim</span> UserName <span style="color: #000080;">As</span> <span style="color: #000080;">String</span>
        <span style="color: #000080;">Dim</span> Password <span style="color: #000080;">As</span> <span style="color: #000080;">String</span>
        <span style="color: #000080;">Dim</span> SysPassword <span style="color: #000080;">As</span> System.Security.SecureString = <span style="color: #000080;">New</span> System.Security.SecureString()
        DomainName = System.Environment.GetEnvironmentVariable(<span style="color: #800000;">&quot;ComputerName&quot;</span>)
        UserName = <span style="color: #800000;">&quot;administrator&quot;</span>
        Password = <span style="color: #800000;">&quot;supersecretpassword&quot;</span>
&nbsp;
        <span style="color: #000080;">For</span> <span style="color: #000080;">Each</span> c <span style="color: #000080;">As</span> Char <span style="color: #000080;">In</span> Password
            SysPassword.AppendChar(c)
        <span style="color: #000080;">Next</span>
        SysPassword.MakeReadOnly()
&nbsp;
        Try
            System.Diagnostics.Process.Start(<span style="color: #800000;">&quot;notepad.exe&quot;</span>, UserName, SysPassword, DomainName)
        Catch ex <span style="color: #000080;">As</span> Exception
            MsgBox(ex.Message)
        <span style="color: #000080;">End</span> Try
        Me.<span style="color: #000080;">Close</span>()
    <span style="color: #000080;">End</span> <span style="color: #000080;">Sub</span>
<span style="color: #000080;">End</span> Class</pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://www.waynezim.com/2009/09/allow-user-to-run-applicaton-as-administrator-without-a-password/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Five Windows Commands Every Administrator Needs To Know</title>
		<link>http://www.waynezim.com/2009/05/five-windows-commands-every-administrator-needs-to-know/</link>
		<comments>http://www.waynezim.com/2009/05/five-windows-commands-every-administrator-needs-to-know/#comments</comments>
		<pubDate>Tue, 26 May 2009 14:10:07 +0000</pubDate>
		<dc:creator>Wayne Zimmerman</dc:creator>
				<category><![CDATA[Tech]]></category>
		<category><![CDATA[Command Line]]></category>
		<category><![CDATA[list]]></category>
		<category><![CDATA[msoobe]]></category>
		<category><![CDATA[netstat]]></category>
		<category><![CDATA[runas]]></category>
		<category><![CDATA[Shutdown]]></category>
		<category><![CDATA[wuauclt]]></category>

		<guid isPermaLink="false">http://www.waynezim.com/?p=160</guid>
		<description><![CDATA[You should always feel like a little ninja when a chance to use the command line rolls around. These command should give you an excuse to open and use the command line just a bit more. wuauclt /detectnow &#8211; This command makes Windows check for updates in accordance with the settings on the workstation. This [...]]]></description>
			<content:encoded><![CDATA[<p>You should always feel like a little ninja when a chance to use the command line rolls around. These command should give you an excuse to open and use the command line just a bit more. </p>
<ul>
<li>
<p><code>wuauclt /detectnow</code>  &#8211; This command makes Windows check for updates in accordance with the settings on the workstation. This is very helpful in domain environments where you have a Windows Server Update Service (WSUS) running and want it to go grab new updates from that server and not use the Microsoft Update website and try to remember which ones you had and hadn&#8217;t approved.</p>
</li>
<li>
<p><code>runas /user:administrator cmd</code>  &#8211; This command is a simple RunAs command that opens command prompt. This is important to know if you want to run other programs as an administrator while leaving a user logged in. This will allows you to start and other program as administrator simply by typing it in your administrator command window. Just be sure to close it when you leave, if not the user will have open reign on the computer using your account.</p>
</li>
<li>
<p><code>oobe/msoobe /a</code> &#8211; This command will start the Microsoft Product Activation Wizard. This may not be the most useful command on the enterprise environment but when it comes to reinstalling a PC for someone you know it is a necessary evil. None the less, when there is no activation link, just run the command it it will get you rolling.</p>
</li>
<li>
<p><code>netstat</code> and <code>netstat -a</code> &#8211; These two commands shows you the IP address, port and other vital information about the connections your computer is using. These information can be helpful when trying to troubleshoot a PC that has slow internet or some type of malware issue, or when you are setting up a new service on your server and trying to determine why you can&#8217;t use a certain port because it is already in use.</p>
</li>
<li>
<p><code>shutdown -i</code> &#8211; Although many people use the shutdown command to shutdown or restart computers, most people don&#8217;t know that this has a handy GUI interface which makes declaring all those parameters in the command line obsolete. Give it a shot and shut down your coworkers computer, but give them some time to see if they can figure out the <code>shutdown -a</code> command to abort your shutdown request. This works especially good to test the new guys skills.</p>
</li>
</ul>
<p>I&#8217;m sure there are many commands I have forgotten to add that are just as great as these, if you think of one put it in the comments and share it with everyone else.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.waynezim.com/2009/05/five-windows-commands-every-administrator-needs-to-know/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

