1
votes

I want to create a password attribute for Contact entity in CRM portal for my organization. I can add it as a "custom attribute" through the designer, and can display it on the form for user to input. However, the problem is that, the attribute, and a field on the form designer are in plain Text format, whereas, I want them as a strict password. That means, they must not be human-readable, and possibly, should be stored in encrypted format.

Any idea on how to achieve it?

Thanks

2
Just wondering why you need to store a password in CRM... - Daryl

2 Answers

4
votes

You can rely on Field Level Security, more details here:

How Field Security Can Be Used to Control Access to Field Values in Microsoft Dynamics CRM

but I suggest a different approach: instead saving the password, why don't store its hash (MD5 or SHA1) and check it inside the authentication process?

1
votes

This is not documented, but you can add this to the form XML for your password field - put this as a child of the < control> node that you want to be a password:

<parameters>
  <IsPassword>true</IsPassword>
<parameters>

If you look at the forms for Mailbox and EmailServerProfile you'll see this being done.

All this does is display * instead of the password - the password is still stored as plain text and anyone with read permissions on the entity can get the value using an SDK call.