Jorge
Mon Aug 18 13:50:22 PDT 2008
adfind -default -f "&(objectcategory=person)(objectclass=user)" -dsq | admod
pwdLastSet::0 -unsafe
will tough EVERY user in the AD domain, so you might want to use:
ADfind -b "DN of OU" instead of adfind -default
--
Cheers,
(HOPEFULLY THIS INFORMATION HELPS YOU!)
# Jorge de Almeida Pinto # MVP Identity & Access - Directory Services #
BLOG (WEB-BASED)-->
http://blogs.dirteam.com/blogs/jorge/default.aspx
BLOG (RSS-FEEDS)-->
http://blogs.dirteam.com/blogs/jorge/rss.aspx
------------------------------------------------------------------------------------------
* How to ask a question -->
http://support.microsoft.com/?id=555375
------------------------------------------------------------------------------------------
* This posting is provided "AS IS" with no warranties and confers no rights!
* Always test ANY suggestion in a test environment before implementing!
------------------------------------------------------------------------------------------
#################################################
#################################################
------------------------------------------------------------------------------------------
"£Jim" <nospam@any.time> wrote in message
news:ulJDQAK$IHA.3656@TK2MSFTNGP03.phx.gbl...
> Hi,
>
> I have a script (vbs) that changes PwdLastSet for a user to zero, and
> that is supposed to force them to change password at next logon but
> they don't get the prompt. I can see that the value is set to zero
> successfully. Are there other account parameters that would stop it
> from working?
>
> I am trying to do a one off forced password change for sections of my
> domain with this from MS:
>
> Set objUser = GetObject _
> ("LDAP://cn=MyerKen,ou=Management,dc=NA,dc=fabrikam,dc=com")
> objUser.Put "pwdLastSet", 0
> objUser.SetInfo.
>
>
http://tinyurl.com/3dvejj
>
> Thanks
>
> --
>