You can find more ADSI script samples (kinda of library) at
http://www.lissware.net

Go to the White Paper section and download the scripts and WP for free.
WHITE PAPERS:

October 2000 (Compaq Active Answers):
Part 1 - Introduction to the use of Exchange 2000 with Windows Script Host
(Script Kit) 
Part 2 - Managing Exchange with Scripts - Advanced Topics (Script Kit) 

February 2000 (Compaq Active Answers):
Part 1 - Understanding the Microsoft WSH and the ADSI in Windows 2000
(Script Kit) 
Part 2 - The powerful combination of WSH and ADSI under Windows 2000 (Script
Kit) 

HTH
/Alain

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of joe
Sent: Thursday, October 20, 2005 4:54 PM
To: ActiveDir@mail.activedir.org
Subject: RE: [ActiveDir] Need ADSI Scripting help.

Well if you have a list of DNs, you will then create a loop in the script
that loops through connecting to those DNs and then grab the UAC attribute
and check to see if the account is disabled (bit 1 is lit, aka value 2) sort
of like

set o=getobject("LDAP://cn=someuser,cn=users,dc=joe,dc=com")
uac=o.useraccountcontrol
if ((uac & 2)=2) then wscript.echo "disabled" else wscript.echo "enabled"

  joe


-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Jitendra Kalyankar
Sent: Thursday, October 20, 2005 5:36 PM
To: ActiveDir@mail.activedir.org
Subject: Re: [ActiveDir] Need ADSI Scripting help.

Wow! Thanks Joe for your reply & also thanks Mark too. I tried my best to
explain to my manager but in vein so I am back to square one. If my own
manager is not comfy with it what will I tell the Security!

I know the scripts are as dangerous as your util or even more so but those
who know how to go about it, not the one who will be using it. Yeah it would
be even better if your oldcmp would guage intelligence ;-), can you do that?
:-D

Anyways I will continue using your utilities free or not. Care to shed more
light on the question I asked? And I guess its more of want to know how you
did it than what my company requires.
Anyways I will find it out sooner or later. But anyways thanks very much
guys for your help.

Sincerely,
Jitendra Kalyankar

On 10/20/05, joe <[EMAIL PROTECTED]> wrote:
> Just as an FYI, scripts are just as dangerous or more so. It is why I 
> wrote oldcmp in the first place. Too many people biting themselves in 
> the ass. I don't know how I could put more rubber bumpers on that tool 
> unless I started asking questions to gauge levels of intelligence and 
> whether or not certain switches should be allowed. :o)
>
> I understand the security department route though too. If they are 
> antsy because it is freeware, let me know and I can charge you 100k or 
> so for it and you get everything you get now plus a bill. :o)
>
>
>
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf Of Jitendra 
> Kalyankar
> Sent: Thursday, October 20, 2005 4:29 PM
> To: ActiveDir@mail.activedir.org
> Subject: Re: [ActiveDir] Need ADSI Scripting help.
>
> I know about the Oldcmp.exe, but the thing is the tool is really 
> powerful and I don't want Jr. Sys. Admins doing something or deleting 
> something that they are not suppose to. And again I will have to go 
> through the security department route to use it. Too much hassel....
>
> Hope that explains my situation.
>
> Sincerely,
> Jitendra Kalyankar
>
> On 10/20/05, Creamer, Mark <[EMAIL PROTECTED]> wrote:
> > Before you do this, see oldcmp at www.joeware.net
> >
> > http://www.joeware.net/win/free/index.htm
> >
> >
> >
> > <mc>
> >
> > -----Original Message-----
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED] On Behalf Of Jitendra 
> > Kalyankar
> > Sent: Thursday, October 20, 2005 4:14 PM
> > To: ActiveDir@mail.activedir.org
> > Subject: [ActiveDir] Need ADSI Scripting help.
> >
> > I am looking for some example script and/or help for the script I am 
> > writing for my company. What I want to achieve is if I run the 
> > script against the machine list which will be in the text file, it 
> > should give me the output in the text file saying which machine 
> > account is enabled, disabled or not found.
> >
> > I know how to manipulate the text files using fso object but I am 
> > not sure what do I need to use to get the attributes of computer 
> > container in AD. Any help in this regard is highly appreciated and
valued.
> >
> > Please let me know if you need more information abou this.
> >
> > --
> > Thanks,
> > Jitendra Kalyankar
> > List info   : http://www.activedir.org/List.aspx
> > List FAQ    : http://www.activedir.org/ListFAQ.aspx
> > List archive:
> > http://www.mail-archive.com/activedir%40mail.activedir.org/
> >
> > This e-mail transmission contains information that is intended to be
> confidential and privileged.  If you receive this e-mail and you are 
> not a named addressee you are hereby notified that you are not 
> authorized to read, print, retain, copy or disseminate this 
> communication without the consent of the sender and that doing so is 
> prohibited and may be unlawful.  Please reply to the message 
> immediately by informing the sender that the message was misdirected.
> After replying, please delete and otherwise erase it and any 
> attachments from your computer system.  Your assistance in correcting 
> this
error is appreciated.
> > List info   : http://www.activedir.org/List.aspx
> > List FAQ    : http://www.activedir.org/ListFAQ.aspx
> > List archive:
> > http://www.mail-archive.com/activedir%40mail.activedir.org/
> >
>
>
> --
> Thanks,
> Jitendra Kalyankar
> List info   : http://www.activedir.org/List.aspx
> List FAQ    : http://www.activedir.org/ListFAQ.aspx
> List archive: 
> http://www.mail-archive.com/activedir%40mail.activedir.org/
>
> List info   : http://www.activedir.org/List.aspx
> List FAQ    : http://www.activedir.org/ListFAQ.aspx
> List archive: 
> http://www.mail-archive.com/activedir%40mail.activedir.org/
>


--
Thanks,
Jitendra Kalyankar
List info   : http://www.activedir.org/List.aspx
List FAQ    : http://www.activedir.org/ListFAQ.aspx
List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/

List info   : http://www.activedir.org/List.aspx
List FAQ    : http://www.activedir.org/ListFAQ.aspx
List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/

List info   : http://www.activedir.org/List.aspx
List FAQ    : http://www.activedir.org/ListFAQ.aspx
List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/

Reply via email to