This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Script for Password policy

I use OIM 8

I need to prohibit users to set a password that match the last x used passwords for AD. For that I am going to use check script in password policy. In that script I want to compare new password's hash with hash from the table QBMPwdHistory. So  my questions:

 

Function header: Public Sub CCC_CustomPwdValidate(Policy As VI.DB.Passwords.PasswordPolicy, spwd As System.Security.SecureString)

1) How can I get the hash of new password in my function for comparing ? As far as I understand I should use something like "Policy.GetHashCode()". May be variable spwd is already in the state which fits for comparing with QBMPwdHistory.HashValue ?

 

2)How can I get XobjectKey of a base object(ADSAccount) in my function? I have found in documentation "To use a base object, take the property Entity of the PasswordPolicy class." However, my variable Policy (VI.DB.Passwords.PasswordPolicy) doesn't have property Entity. Please help.

Parents Reply
  • Markus, I designed script according to your recommendation, however recently I have found a problem, I can’t change password in standard web form for changing password. I get an policy error “Object reference not set to an instance of an object” . I get the same error in designer if I don’t choose base object for checking policy. So I can’t understand why base object is not chosen for changing password on web portal because before resetting password asks for account. Do you think that this is system bug, or I make something wrong?

    P.S. Version OIM 8.0.1

Children