title: PsExec works only with "runas /netonly", not with -u and -p parameters
body: <blockquote>
  <p>What I mean:</p>
  </blockquote>
  <p><strong>If I...</strong></p>
  <ol>
  <li><p>run <code>runas /netonly /user:computername\username cmd</code></p>
  </li>
  <li><p>enter the password for the local admin account &quot;username&quot;</p>
  </li>
  <li><p>then type <code>psexec \\computername cmd</code></p>
  </li>
  </ol>
  <p>I now have a working shell and can run commands as the local admin user on the remote machine.</p>
  <p><strong>However</strong>, trying to run this <em>without</em> the runas... and <em>instead</em> with the username and password arguments of <code>psexec</code> returns an access denied error.</p>
  <blockquote>
  <p>Example below:</p>
  <p><code>psexec \\computername -u username -p password cmd</code></p>
  <p><code>Access Denied</code></p>
  </blockquote>
  <p><strong>Note:</strong> Others seem to also have this issue. <strong>My refined questions:</strong></p>
  <ul>
  <li><em>Is this intended behavior?</em></li>
  <li><em>Why even have the <code>-u</code> and <code>-p</code></em>?</li>
  </ul>
  <p>I have also tried disabling the firewall on both my machine and the target machine, and adding the registry key listed <a href="https://stackoverflow.com/questions/828432/psexec-access-denied-errors">here</a>.</p>