Configure Salesforce for AppFabric
Salesforce makes cloud-based software designed to help businesses find more prospects, close more deals, and wow customers with amazing service. Salesforce’s Customer 360 offers a complete suite of products, unites sales, service, marketing, commerce, and IT teams with a single, shared view of customer information, helping organizations grow relationships with customers and employees alike.
You can use AWS AppFabric to receive audit logs and user data from Salesforce, normalize the data into Open Cybersecurity Schema Framework (OCSF) format, and output the data to an Amazon Simple Storage Service (Amazon S3) bucket or an Amazon Data Firehose stream.
AppFabric support for Salesforce
AppFabric supports receiving user information and audit logs from Salesforce.
Prerequisites
To use AppFabric to transfer audit logs from Salesforce to supported destinations, you must meet the following requirements:
-
You must have a Performance, Enterprise, or Unlimited edition
of Salesforce. Contact Salesforce to upgrade to one of these editions. -
If you are seeking to have AppFabric transfer hourly event log files with full set of log events
from Salesforce, you must subscribe to Event Monitoring as part of the Shield Features of Salesforce. Otherwise, AppFabric will transfer limited events (i.e. Login, Logout, InsecureExternalAssets, API Total Usage, CORS Violation, and HostnameRedirects ELF Events) from Salesforce’s standard daily log file. You can check if your Salesforce account is already subscribed to Shield Features by going to Setup > Event Manager. If you see 19 or more events listed, your account is subscribed to the Event Monitoring. If you do not have Event Monitoring, you can purchase a subscription to this add-on by contacting Salesforce. -
You need to opt-in for Event Log File generation
in the Salesforce settings. -
You should use the System Administrator Profile to create an OAuth application and log in with the same credentials for AppFabric.
Note
The API Total Usage, CORS Violation Record, Hostname Redirects, Insecure
External Assets, Login, and Logout events are available at no additional cost in
supported editions of Salesforce. Contact
Salesforce to purchase the remaining event types. For more
information about Salesforce event types, see EventLogFile Supported Event Types
AppFabric can support up to 100,000 events per event type per log file instance (daily or hourly, depending on Event Monitoring add-on subscription). A log file exceeding the threshold might cause the entire log file to be excluded from ingestion.
Rate limit considerations
Salesforce imposes rate limits on the Salesforce
API. For more information about the Salesforce API rate limits, see
API Request Limits and Allocations
Data delay considerations
You might see up to 6 hours delay on daily log file or up to 29 hours delay on
hourly log file for an audit event to be delivered to your destination. This is due
to delay in audit events made available by the application as well as due to
precautions taken to reduce data loss. However, this might be customizable at an
account-level. For assistance, contact AWS Support
Connecting AppFabric to your Salesforce account
After you create your app bundle within the AppFabric service, you must authorize AppFabric with Salesforce. To find the information required to authorize Salesforce with AppFabric, use the following steps.
Create an OAuth application
AppFabric integrates with the Salesforce using OAuth. To create an OAuth application in Salesforce, use the following steps:
-
Go to the Setup page as described in the Salesforce documentation
. -
Search for App Manager in the quick find.
-
Choose New Connected App.
-
Enter the required information into the form fields.
-
Choose Enable OAuth settings.
-
Be sure to turn off the following options:
-
Require Proof Key for Code Exchange (PKCE) Extension For Supported Authorization Flows
-
Require secret for Web Server Flow
-
Require secret for Refresh Token Flow
-
Enable Refresh Token Rotation
-
-
Enter a URL with the following format in the Callback URL text box, and choose Save changes.
https://
<region>
.console.aws.amazon.com/appfabric/oauth2In this URL,
<region>
is the code for the AWS Region in which you configured your AppFabric app bundle. For example, the code for the US East (N. Virginia) Region isus-east-1
. For that Region, the redirect URL ishttps://
.us-east-1
.console.aws.amazon.com/appfabric/oauth2 -
Fill in the scopes as needed (described in the following Required scopes section). All other fields can be left with their default values.
-
Choose Save.
-
Complete the following steps to verify the refresh token policy for the new OAuth app:
-
On the Setup page, enter Connected Apps into the Quick Find text box, and then choose Manage Connected Apps.
-
Choose Edit next to the newly created app.
-
Make sure that the Refresh token is valid until revoked option is selected.
-
Save your changes.
-
-
Complete the following steps to verify that audit logs are being generated:
-
On the Setup page, enter Event Log File into the Quick Find text box, and then choose Event Log File Browser.
-
Confirm that event logs are listed in the Event Log File Browser.
-
-
Navigate to the created app, and choose View from the drop-down.
-
Choose Manage Consumer Details.
You will be redirected to a new tab where you will need to verify your identity. On that tab, make a note of the Consumer Key and Consumer Secret values. You will need these later to sign in.
Required scopes
You must add the following scopes to your Salesforce OAuth application:
-
Manage user data via APIs (
API
). -
Perform request at anytime (
refresh_token
andoffline_access
).
App authorizations
Tenant ID
AppFabric will request your tenant ID. The tenant ID in AppFabric is the subdomain of
your Salesforce
My Domain. You can find your My Domain
subdomain in your browser's address bar between https://
and
.my.salesforce.com
.
To find your Salesforce My Domain, use the following instructions from the Salesforce home screen.
-
Go to the Setup page as described in the Salesforce documentation
. -
Search for Company Settings in the quick find, and choose My Domain in the results.
Tenant name
Enter a name that identifies this unique Salesforce organization. AppFabric uses the tenant name to label the app authorizations and any ingestions created from the app authorization.
Client ID
AppFabric will request a client ID. To find your client ID in Salesforce, use the following steps:
-
Navigate to the Setup page.
-
Choose Setup, and then choose App Manager.
-
Choose the created app, and choose View from drop-down menu.
-
Choose Manage Consumer Details. You will be redirected to a new tab.
-
Verify your identity, and then look for the Consumer Key value.
-
Enter the Consumer Key into the client ID field in AppFabric.
Client secret
AppFabric will request your client secret. The Client secret in AppFabric is the Consumer Secret in Salesforce. To find your Secret in Salesforce, use the following steps:
-
Navigate to the Setup page.
-
Choose Setup, and then choose App Manager.
-
Choose the created app, and choose View from drop-down menu.
-
Choose Manage Consumer Details. You will be redirected to a new tab.
-
Verify your identity, and then look for the Consumer Secret value.
-
Enter the Consumer Secret into the client secret field in AppFabric.
Approve authorization
After creating the app authorization in AppFabric, you will receive a pop-up window from Salesforce to approve the authorization. At the approval page, make sure to use the Salesforce System Administrator Role or a Salesforce user that have View Event Log Files and API Enabled user permissions while authorizing. Choose Allow to approve the AppFabric authorization.