Re: Giving Accounts Local Computer Admin Privledge
- From: "Richard Mueller" <rlmueller-NOSPAM@xxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 4 Jan 2006 12:07:26 -0600
Hi,
You can modify local group memberships in a startup script (via GPO). They
run with elevated privileges locally and with the privileges of the computer
object in the domain. Best is to create a domain group for this purpose,
then make the domain group a member of the local Administrators group. Then
you can manage membership on the domain without messing with the local
groups again. The Startup script can first check if the domain group has
already been added. The Startup script must use the WinNT provider. I have
used code similar to:
Dim strDomainGroup, objDomainGroup, objNetwork
Dim strComputer, objLocalGroup
' Specify AdsPath of domain group to be added to
' local Administrators group.
strDomainGroup = "WinNT://MyDomain/AdmGroup,group"
Set objDomainGroup = GetObject(strDomainGroup)
' Retrieve local computer NetBIOS name.
Set objNetwork = CreateObject("Wscript.Network")
strComputer = objNetwork.ComputerName
' Bind to local Administrators group.
Set objLocalGroup = GetObject("WinNT://" & strComputer _
& "/Administrators,group")
' Check if domain group already a member.
If Not objLocalGroup.IsMember(objDomainGroup.AdsPath) Then
' Add domain group to local group.
objLocalGroup.Add(objDomainGroup.AdsPath)
End If
--
Richard
Microsoft MVP Scripting and ADSI
Hilltop Lab - http://www.rlmueller.net
"Neil Ruston" <NeilRuston@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:CD0775F5-B205-4D4A-A46A-576EB3EBE99D@xxxxxxxxxxxxxxxx
> Simply add those accounts to the local Administrators group, on the
> relevant
> machine(s).
>
> Restricted Groups (via GPO) may also be worth investigating.
>
> hth,
> neil
>
>
>
>
>
> "Jeremy Dillinger" wrote:
>
>> Is there a way I can give accounts in Active Directory Local Computer
>> Admin
>> Privledge without giving them domain admin privledge? How can I go about
>> doing this? Thanks!
>>
>> Jeremy
>>
>>
>>
.
- References:
- Giving Accounts Local Computer Admin Privledge
- From: Jeremy Dillinger
- Giving Accounts Local Computer Admin Privledge
- Prev by Date: Re: Enumerate User Attributes
- Next by Date: Re: No Network Connection
- Previous by thread: Giving Accounts Local Computer Admin Privledge
- Next by thread: Re: LDAP [WildPacket]
- Index(es):
Relevant Pages
|