Re: Running a .bat file on a server in another domain

Tech-Archive recommends: Fix windows errors by optimizing your registry

From: JW (JW_at_discussions.microsoft.com)
Date: 09/23/04


Date: Wed, 22 Sep 2004 18:53:02 -0700

I don't think so, first of all I am passing my credentials to the domain in
question which is on our internal network and of which I am an enterprise
admin. Also this is no different from running a script on any other server
that I would want to attach to with alternate credentials. Here is a
description of the SWbemLocator- “You can use the methods of the SWbemLocator
object to obtain an SWbemServices object that represents a connection to a
namespace on a local or remote host computer. You can then use the methods of
the SWbemServices object to access WMI. This object can be created by the
VBScript CreateObject call.” What I am trying to do is create a script that
will patch all of my Domain Controllers on a particular domain.

"David Wang [Msft]" wrote:

> Sounds like access-denied by-design.
>
> What you are trying to do is no different than an external hacker trying to
> run "D:\DSUpdate\HackTheDomain.bat"
>
> --
> //David
> IIS
> This posting is provided "AS IS" with no warranties, and confers no rights.
> //
> "JW" <JW@discussions.microsoft.com> wrote in message
> news:305E0A84-63C2-4C54-9276-71F7AF69BD00@microsoft.com...
> I am writing a script to run a .bat file to kick off a Q-Chain on all of the
> Domain Controllers in a given domain. How can I get my batch file to run
> when the Domain Controller is in a different, non-trusted domain? All of
> the
> methods I've found so far for passing authentication do not allow for
> something like...
>
> strCommand = "d:\DSUpdate\update.bat"
> errReturn = objWMIService.Create(strCommand, Null, Null, intProcessID)
>
> I've been fighting with this one for a while now and any help would be
> greatly appreciated.
>
>
>



Relevant Pages

  • Re: Running a .bat file on a server in another domain
    ... You are logged in as user A in domain A and execute this script against ... machine B in domain B. Which credentials are you passing: ... the SWbemServices object to access WMI. ...
    (microsoft.public.windows.server.scripting)
  • Re: Running a .bat file on a server in another domain
    ... User A is enterprise admin in Domain A. User B is enterprise admin in Domain ... I am passing User B's credentials to the server in Domain B. ... > the SWbemServices object to access WMI. ...
    (microsoft.public.windows.server.scripting)