We help IT Professionals succeed at work.

Need Active Directory custom search to find account that do not expire

SigSupport
SigSupport asked
on
Medium Priority
842 Views
Last Modified: 2012-05-07
Hi,
I need to find which of my AD users are not expiring.
I found something that looks like it but doesn't work when cutting and pasting it in a custom search:

"(&(objectCategory=person)(objectClass=user)" _
    & "(|(accountExpires=9223372036854775807)(accountExpires=0)))"

I have also found this:
strFilter = "(&(objectCategory=person)(objectClass=user)" _
& "(userAccountControl:1.2.840.113556.1.4.803:=65536))"

But they don't work, can you tell me what is the EXACT semantic I can just cut and paste in the "Enter LDAP query"  field.
Tx!
Comment
Watch Question

Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION
CERTIFIED EXPERT
Top Expert 2013
Commented:
Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION

Author

Commented:
With these answers I will get exactly what I need.
Thanks!
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a sample view!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.