MicroStrategy ONE

Adding Custom Password Validation Rules

In this scenario, you add custom password rules that are validated each time a user changes his or her password. For example, you can specify that a password must consist of six alphanumeric characters and include at least one numeric character and one capitalized alpha character. Or, you may want to specify that a user cannot include his or her name in the password or reuse any of the previous five passwords. This feature allows you to integrate corporate password policy into your MicroStrategy applications.

This customization can be accomplished using either of the following methods:

Deploying the plug-in provided with MicroStrategy SDK

MicroStrategy SDK provides a plug-in (ZIP file) that can simply be extracted to thepluginsfolder to view the customization in MicroStrategy Web. The following steps guide you in locating the plug-in and deploying it. 

  1. Access the plug-in: JSP version or ASP .NET version

  2. Extract the plug-in to the plugins subfolder inside the MicroStrategy Web installation folder.   

  3. Launch MicroStrategy Web to view the customization.

Using the Web Customization Editor to create a plug-in

MicroStrategy SDK provides a Web Customization Editor that can be used to create a customization plug-in. The following steps guide you in creating the plug-in and deploying it. 

  1. Launch the Web Customization Editor

  2. Click on MicroStrategy Web Configuration inside the Application Settings view to expand the hierarchical tree. The expanded list comprises the different settings that can be modified to perform customizations. 

  3. Click on Pages to expand the list of pages used in MicroStrategy Web. 

  4. Navigate to chPwd (Change Password)->Beans

  5. Right-click changePassword (Type=ChangePasswordBean) and select New Event Handler. This launches the Custom Event Handler Creation wizard. In this step you create an event handler that contains logic to check whether new passwords contain between six and eight characters and have at least one numeric character. 

  6. Click Browse to select the source folder for the project. 

  7. Enter com.microstrategy.sdk.samples.events in the Package text field. 

  8. Enter CustomChangePasswordEventHandler in the Name text field. 

  9. Select the radio button for Use Existing Event

  10. Click Next

  11. Click Finish. CustomChangePasswordEventHandler.java opens in the editor. The sample, CustomChangePasswordEventHandler.java, contains the entire code for this custom event handler.  This code contains logic to check whether new passwords contain between six and eight characters and have at least one numeric character. You can modify this sample code to use other password rule logic by replacing the code that follows the comment  //Custom logic to validate password and precedes the comment //Regular handling to change password

  12. Save your changes. 

  13. Navigate to Pages->prefChPwd (Preferences Change Password)->Beans->changePassword (Type=ChangePasswordBean)

  14. Double-click changePassword (Type=ChangePasswordBean) to launch the Bean Properties editor in the right frame. 

  15. In the Properties section, enter com.microstrategy.sdk.samples.events.CustomChangePasswordEventHandler in the text field for Event Handler

  16. Save your changes. 

  17. Launch MicroStrategy Web to view the customization.

See Also