000025217 - How to access ClearTrust user properties in Web service

Document created by RSA Customer Support Employee on Jun 16, 2016Last modified by RSA Customer Support Employee on Apr 21, 2017
Version 2Show Document
  • View in full screen mode

Article Content

Article Number000025217
Applies ToRSA ClearTrust Agent 4.5 for Microsoft IIS
Microsoft Windows Server 2003
IssueHow to access ClearTrust user properties in Web service
CauseClearTrust user properties allow for power and flexibility in generating dynamic content of Web pages or dynamic authorization. Where a Web service is being consumed by a client rather than a user browsing a Web site with their browser, it becomes less clear on how this may operate.
ResolutionClearTrust user properties can be transmitted as part of the HTTP request header; this means a standard Web service can access the variable in the same way as text ASP pages might. To see an example of this, carry out the following steps:

1. Create a property called "telephoneNumber" as a string property (if an LDAP datastore is in use, this property will be available in the standard user class)

2. Assign a property value for "telephoneNumber:" to a chosen user

3. Edit the Application that has been configured to protect your Web service and enable the chosen property to be used by this service

4. Modify the cleartrust.agent.userprops value to read as follows:

    cleartrust.agent.userprops=telephoneNumber

5. Inside the Web service, the variable will be now available as a server variable and can be accessed. For example, in C#, this could read as follows:

    String phone = this.Context.Request.ServerVariables.Get("HTTP_TELEPHONENUMBER");
Legacy Article IDa20213

Attachments

    Outcomes