Share via


profiles Tag

The profiles tag is used for configuring the user profiles and catalog sets functionality. It describes the high-level schema implemented by the User and Organization profiles to the runtime. This information is used by the CommerceContext object in its implementation of the userProfile and organizationProfile smart properties and in the CommerceContext.GetGatalogsForUser method. There is no configuration that can be done using the profiles tag alone, it is simply a container for other tags.

The profiles tag contains three optional tags: encryption, userProfile, and organizationProfile.

encryption Tag

This tag denotes the description of the encryption key configured in the Profiling System.

The encryption tag is required if the application will read or write asymmetrically encrypted profile members, otherwise it is optional. There is no configuration that can be done using the encryption tag alone, it is simply a container for other tags.

The encryption tag contains one tag, the keys tag.

keys Tag

The keys tag contains one tag, the add tag. A maximum of three add tags may be added to a keys tag.

The following table lists the attribute of the keys tag.

Attribute Data Type Description
keyIndex Integer Denotes the current key pair used for encryption/decryption.

The set of valid values is 1 or 2.

If the keyIndex attribute is set to 1, then the add tag type attribute values of publicKey and privateKey1 form the current key pair.

If the keyIndex attribute is set to 2, then the add tag type attribute values of publicKey and privateKey2 form the current key pair.

This attribute is required if the application writes to asymmetrically encrypted profile properties. This attribute must be used in conjunction with an add tag whose type attribute is PublicKey.

add Tag

A maximum of three add tags may be added to a keys tag.

The following table lists the attributes of the add tag.

Attribute Data Type Description
type String The type of public/private keys used for encryption/decryption.

The set of valid set of case sensitive values are publicKey, privateKey1, and privateKey2. The publicKey is required if the keyIndex attribute is specified as they must be provided together.

The publicKey is required if the application writes to asymmetrically encrypted profile properties or if the keyIndex attribute is set, as they keyIndex attribute must be used in conjunction with the publicKey.

The privateKey1 is required if the application reads asymmetrically encrypted profile properties that were encrypted when the keyIndex attribute was set to 1. Otherwise the privateKey1 is optional.

The privateKey2 is required if the application reads asymmetrically encrypted profile properties that were encrypted when the keyIndex attribute was set to 2. Otherwise this attribute is optional.

This attribute is case sensitive.

value String The hexadecimal string for the type attribute specified. Only keys generated using the Microsoft Windows CryptoAPI routines are valid. For more information about generating keys for the value attribute, see Generating public and private keys.

This attribute is case sensitive.

To determine the keyIndex value used to encrypt the profile, query the profile member used to save the keyIndex value. Definition of a profile member used to save the keyIndex attribute is mandatory in profiles using asymmetric encryption. For more information about asymmetric encryption, see Managing Encrypted Profile Properties.

There are several acceptable combinations of the encryption tag attributes. For encryption, the recommended combination is PublicKey + KeyIndex. For decryption, the recommended combination is PrivateKey1 + PrivateKey2. For both encryption and decryption, the recommended combination is PublicKey + KeyIndex + PrivateKey1 + PrivateKey2.

For more information about generating public and private key pairs or defining encrypted members on profiles, see Managing Encrypted Profile Properties.

userProfile Tag

This tag denotes the description of the User profile configured in the Profiling System.

The following table lists the attributes of the userProfile tag.

Attribute Data Type Description
profileDefinition String The name of the profile definition that corresponds to a user in the Profiling System.

This attribute is optional.

Default value is UserObject.

userIdProperty String The property in the user profile that stores the unique user ID. This should not be confused with the logon name; the user ID is the primary key used to distinguish all instances of the user profile from each other.

This attribute is optional.

Default value is user_id.

organizationIdProperty String The property in the user profile that stores the unique identifier of the instance of the organization profile with which the user profile is associated.

This attribute is optional.

Default value is AccountInfo.org_id.

catalogSetIdProperty String The property in the user profile that stores the catalog set or sets with which a particular instance of the user profile is associated.

This attribute is optional.

Default value is AccountInfo.user_catalog_set.

organizationProfile Tag

This tag denotes the description of the Organization profile configured in the Profiling System.

The following table lists the attributes of the organizationProfile tag.

Attribute Data Type Description
profileDefinition String The name of the profile definition that corresponds to an organization in the Profiling System.

This attribute is optional.

Default value is Organization.

organizationIdProperty String The property in the organization profile that stores the unique identifier of the instance of the organization profile that distinguishes it from all other instances of organization profiles.

This attribute is optional.

Default value is GeneralInfo.org_id.

catalogSetIdProperty String The property in the organization profile that stores the catalog set or sets with which a particular instance of the organization profile is associated.

This attribute is optional.

Default value is GeneralInfo.org_catalog_set.

Example

<profiles>
    <userProfile
        profileDefinition="UserObject"
        userIdProperty="GeneralInfo.logon_name"
        organizationIdProperty="AccountInfo.org_id"
        catalogSetIdProperty="AccountInfo.user_catalog_set"
    />
    <organizationProfile
        profileDefintion="Organization"
        organizationIdProperty="GeneralInfo.org_id"
        catalogSetIdProperty="GeneralInfo.org_catalog_set"
    />

   <encryption>
       <keys keyIndex="1">
           <add type="publicKey" value="<hex-string>" />
           <add type="privateKey1" value="<hex-string>" />
           <add type="privateKey2" value="<hex-string>" />
       </keys>
  </encryption>

</profiles>

See Also

Configuration Services

Business Desk Profiles

CommerceContext Class

Profile Class

Copyright © 2005 Microsoft Corporation.
All rights reserved.