Page 1 of 1 1
Topic Options
#187745 - 2008-05-20 11:23 AM Delete property security??
Jlmartinez Offline
Getting the hang of it

Registered: 2008-05-20
Posts: 75
Loc: Sevilla, Spain
I would remove the user "All" and "User" from property of security because they are as local administrators. Sorry my english , i´m spanish boy and thanks for your help everyone!!!
Top
#187747 - 2008-05-20 01:22 PM Re: Delete property security?? [Re: Jlmartinez]
Glenn Barnas Administrator Offline
KiX Supporter
*****

Registered: 2003-01-28
Posts: 4402
Loc: New Jersey
A call to XCACLS.exe would be the simplest solution.

Glenn
_________________________
Actually I am a Rocket Scientist! \:D

Top
#187776 - 2008-05-21 08:25 AM Re: Delete property security?? [Re: Glenn Barnas]
Jlmartinez Offline
Getting the hang of it

Registered: 2008-05-20
Posts: 75
Loc: Sevilla, Spain
ummm!! I'm sorry, but I have little time with Kix. How should I do?
Top
#187779 - 2008-05-21 09:12 AM Re: Delete property security?? [Re: Jlmartinez]
Arend_ Moderator Offline
MM club member
*****

Registered: 2005-01-17
Posts: 1896
Loc: Hilversum, The Netherlands
XCACLS.exe ..... outdated, then at least suggest xcacls.vbs and since this is a kix forum, I'd suggest my NTFSPerms UDF \:\)
Top
#187784 - 2008-05-21 10:15 AM Re: Delete property security?? [Re: Arend_]
Jlmartinez Offline
Getting the hang of it

Registered: 2008-05-20
Posts: 75
Loc: Sevilla, Spain
ok thanks for all, i will investigate this solution.

another similar question, how can I remove "ALL" and "User" from group local admin of the machine? Thanks

Top
#187785 - 2008-05-21 10:34 AM Re: Delete property security?? [Re: Jlmartinez]
Arend_ Moderator Offline
MM club member
*****

Registered: 2005-01-17
Posts: 1896
Loc: Hilversum, The Netherlands
Whipped up a quick function to do that:
 Code:
Function RemoveFromLocalAdmin($userName)
  Dim $WMIgroups, $obj, $adms
  $WMIgroups = GetObject("WinMgmts:root/cimv2").ExecQuery("Select * FROM Win32_Group Where LocalAccount = True")
  For Each $obj in $WMIgroups
    If $obj.SID = "S-1-5-32-544"
      ? $obj.Name
      $adms = GetObject("WinNT://"+@WKSTA+"/"+$obj.Name)
      If $adms.IsMember("WinNT://"+@LDOMAIN+"/"+$username)
        $adms.remove("WinNT://"+@LDOMAIN+"/"+$username)
      EndIf
    EndIf
  Next
EndFunction


You can edit this function easily to use it for remote machines, I don't have the time anymore ;\)

Top
Page 1 of 1 1


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 1644 anonymous users online.
Newest Members
Viginette, ManuvdWielNL, Sir_Barrington, batdk82, StuTheCoder
17888 Registered Users

Generated in 0.128 seconds in which 0.101 seconds were spent on a total of 13 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org