Author: Garrett OBrien
Author Notes: This java program will loop through a given group and add secEnterprise aliases to each user in that group if they don’t have one each with a given password. The alias name will be the exact same as the existing user name. The purpose of this is to add Enterprise aliases to AD/NT/LDAP/etc users.
Platform: Java, tested on BOE XIr2, but it should work with any version
The program is a .JAR file, and can be renamed from .ZIP to .JAR
This program can be run from the command line, or published to BOE as a Java application and scheduled through BOE.
To run this from the command line, you have to have to have the BOE libraries available (preferably local) as well as java installed. The command line would be:
java -Djava.ext.dirs=“FULL_PATH_OF_LIBRARIES” -jar MakeEnterpriseAliases.jar CMSUSERNAME CMSPASSWORD CMSNAME GROUPNAME NEWPASSWORD
To run this through BOE, publish the .JAR file as a Java program and set the logon username and password to the proper system credentials if needed. Set the classpath to MakeEnterpriseAliases and set the arguments to GROUPNAME NEWPASSWORD (the actual group name and new password – if they have spaces, surround each with double quotes – e.g. “my group” “my password”). This can then be scheduled as needed.
The .java source file is in the .jar file, so that can be extracted with WinZip or some other zip application and modified.
I wrote this in about 20 minutes including testing, so it hasn’t been extensively tested. I would suggest looking at the .java source code to see how it works. It’s such a simple program that it shouldn’t cause issues, but, as always, use at your own risk.
MakeEnterpriseAliases.zip (3.0 KB)
gobrien (BOB member since 2008-03-14)