Loading
Prepare for Email to Become the Default Login ExperienceRead More
B2B Commerce for Visualforce
Assign Records Created by Guest Users to a Default Owner for B2B Commerce for Visualforce

Assign Records Created by Guest Users to a Default Owner for B2B Commerce for Visualforce

The security alert Assign Records Created by Guest Users to a Default Owner adds a Digital Experiences setting, Assign new records created by guest users to the default owner. When enabled, this setting restricts a guest user from owning any sObject records, including B2B Commerce for Visualforce custom objects such as CC Carts. To complete this security alert, create a user that you can assign as the default owner for guest user records.

Required Editions

Salesforce Compatibility

Salesforce Classic and Lightning Experience for Enterprise, Performance, Unlimited, and Developer editions.

B2B Commerce Compatibility

  • B2B Commerce for Visualforce Winter ’21 (version 4.13) release build 3.149 or later
  • B2B Commerce for Visualforce Spring ’20 (version 4.12) release build 3.147 or later
  • B2B Commerce for Visualforce Summer ’19 (version 4.11) patch 3.145.9 or later
  • B2B Commerce for Visualforce Spring ’19 (version 4.10) patch 3.142.20 or later
  • B2B Commerce for Visualforce Summer ’18 (version 4.9) patch 3.136.36 or later
  • CloudCraze 4.8 patch 3.133.24 or later
  • CloudCraze 4.7 patch 3.124.36 or later
User Permissions Needed
To create an account: Create on accounts
To create a contact: Create on contacts
To create a user: Manage Internal Users
To clone a permission set: Manage Profiles and Permission Sets
To assign a permission set: Assign Permission Sets
To access CC Admin and change settings: Access B2B Commerce for Visualforce Admin Settings permission set
  1. If you haven't already done so, upgrade the available global data. The patch you installed adds a configuration, Default Record Owner, in the User Profile (Registration) module in your storefront configuration settings.
    1. On the CC Admin tab in your org, select Data Loader from the Global Settings menu.
    2. In Upgrade B2B Commerce Settings, click Upgrade.
      Note
      Note If you're using B2B Commerce for Visualforce Summer ’18 (version 4.9) or earlier—including CloudCraze 4.8 or 4.7—the Upgrade button isn't available. Instead, manually create the required configuration metadata. Complete the steps in Create Metadata for Configurations Added in a Patch.
  2. Clone the default Customer Community Plus User profile. In the next step, you assign this profile to the user that becomes the default owner of all records created by guest users.
    Note
    Note Optionally, you can use the existing clone of the default Customer Community Plus User profile that you created when you first installed the managed package. The only requirement is that the profile is for a Customer Community Plus user license.
    1. From Setup, enter Profiles in the Quick Find box, and then select Profiles.
    2. Find the Customer Community Plus User profile, and click Clone in the Action column.
    3. Enter a unique Profile Name, and click Save.
  3. Create a user that becomes the default owner of all records created by guest users.
    1. Create an account specifically for this user.
    2. Create a contact for the account.
    3. On the contact detail page, select Manage External User.
      • In Lightning Experience, click the contact dropdown menu and select Enable Customer User.
      • In Salesforce Classic, click Manage External User, and then select Enable Customer User.
    4. Complete the fields for the user record.
      • For User License, select Customer Community Plus.
      • For Profile, verify that the clone of the Customer Community Plus User profile you created in the previous step is selected.
  4. Create a permission set for the user that you created. Clone the default B2B Commerce Guest permission set, and modify it to add read access to the CC Contact Addresses and CC Orders objects.
    Note
    Note
    • If you're using B2B Commerce for Visualforce Summer ’18 (version 4.9) or earlier—including CloudCraze 4.8 or 4.7—this permission set is named CloudCraze Guest.
    • This clone of the default guest user permission set is used exclusively for the default owner of all records created by guest users.
    1. From Setup, enter Permission in the Quick Find box, and then select Permission Sets.
    2. Find the B2B Commerce Guest permission set, and click Clone in the Action column.
    3. Enter a unique Label and API Name, and save your changes.
    4. On your cloned permission set details, click Object Settings.
    5. Select the CC Contact Addresses object, and click Edit.
    6. In the Object Permissions section, select the Enabled column for the Read permission, and click Save.
    7. Select the CC Orders object, and click Edit.
    8. In the Object Permissions section, select the Enabled column for the Read permission, and click Save.
  5. Assign the cloned permission set to the user that you created.
    1. From Setup, enter Users in the Quick Find box, and then select Users.
    2. Select the user that you created.
    3. Scroll to the Permission Set Assignments section, and click Edit Assignments.
    4. Add the cloned permission set to the list of Enabled Permission Sets.
    5. Click Save.
  6. Update your storefront configuration settings with the ID of the user that you created.
    Browse to your storefront's configuration settings.
    1. On the CC Admin tab in your org, select your storefront (1).
    2. In the Storefront Settings menu, select Configuration Settings (2).
    3. Click New New configuration setting, enter the following values in the New Page Setting window, and click Create.
      Field Value
      Module User Profile (Registration)
      Configuration Default Record Owner
      Page all
      Value The 15-digit ID of the user that you created.
    4. Build and activate a new configuration cache.
  7. Complete the Assign Records Created by Guest Users to a Default Owner security alert.
    1. From Setup, enter Security Alerts in the Quick Find box, and then select Security Alerts.
    2. Find the Assign Records Created by Guest Users to a Default Owner security alert, and click Get Started.
    3. For the step named Enable the Feature in Your Org, follow the instructions in the alert to enable the setting. When you're done, click Mark as complete.
    4. For the step named Assign a Default Owner in Communities, select the user that you created. When you're done, click Mark as complete.
    5. For the step named Reassign Records Owned by Guest Users, review any records that the storefront guest user currently owns. Update each affected record so that the user you created is the new owner. When you're done, click Mark as complete.
    6. Complete the remaining steps in the alert.
Tip
Tip If you decide to change which user is the default owner for records that guest users create, repeat all these steps with the new user ID.
 
Loading
Salesforce Help | Article