JSI Tip 9911. How can I save and recall the switches I use with ADFind.exe freeware?


The new version of ADFind.exe freeware allows you to create and ADFind.cf file that contains the switches that you always use.

You can create a AnyName.cf for specific purposes.

I have created a ADFcsv.cf file to hold the switches that I use when creating a CSV format output. The ADFcsv.cf file contains:

-default
-bit
-nodn
-tdc
-tdcs
-samdc
-csv
-csvdelim ;
-csvmvdelim #
Instead of having to type:
adfind -default -bit -nodn -tdc -tdcs -samdc -csv -csvdelim ; -csvmvdelim # -f "&(objectcategory=Person)(objectClass=User)" sAMAccountName distinguishedName userPrincipalName MemberOf userAccountControl lastLogon
I can type:
adfind -ef c:\util\ADFcsv.cf -f "&(objectcategory=Person)(objectClass=User)" sAMAccountName distinguishedName userPrincipalName MemberOf userAccountControl lastLogon
The output might look like:
"sAMAccountName";"distinguishedName";"userPrincipalName";"MemberOf";"userAccountControl";"lastLogon"
"Test";"CN=Test.User,CN=Users,DC=JSIINC,DC=COM";"[email protected]";"CN=Accounts Payables,CN=Users,DC=JSIINC,DC=COM#CN=accountants,CN=Users,DC=JSIINC,DC=COM";"66048 \[NORMAL_USER(512);NO_EXPIRE(65536)\]";"2005/11/15-23:55:00 Eastern Standard Time"
NOTE: See the following tips:
How can I use environment variables to define commonly used ADFind.exe freeware switches?

ADFind.exe freeware can use :AND: and :OR: instead of :1.2.840.113556.1.4.803: and :1.2.840.113556.1.4.804: to define a bitwise filter.

ADFind.exe freeware allows you to save and recall query filters.



Hide comments

Comments

  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
Publish