FAQ-000764 - E-commerce and Shipping Security / E-commerce Platform Integration Security

Current Status:VALID_RESPONSEErrorUnable to AnswerSuggests Case

Current FAQ

Question
What security considerations are specific to e-commerce and shipping integration applications?
Answer
Security considerations for e-commerce and shipping integration applications include: 1. **Secure Communication**: Use secure connections like HTTPS or SFTP for data exchanges. Avoid unsecured protocols like HTTP or FTP, and implement HTTP Strict Transport Security (HSTS) to prevent downgrade attacks. 2. **Authentication and Authorization**: Authenticate and authorize all requests, especially for privileged actions or sensitive data. Enforce these measures for accessing or modifying confidential objects like orders, customer information, or payment details. 3. **Encryption and Cryptography**: Protect data at rest with strong encryption methods and safeguard encryption keys. Use supported cryptography APIs and avoid custom implementations. 4. **Sensitive Data Handling**: Identify and document sensitive data such as payment information, personally identifiable information, and access tokens. Redact sensitive data in logs and disclose storage or processing details to customers. 5. **User Input Validation**: Validate all user inputs to ensure they match expected data types. Escape user-provided content before rendering it in any context, including HTML and JavaScript, to prevent code injection. 6. **Cross-Site Request Forgery (CSRF) Protection**: Include CSRF protection in all state-changing controllers to mitigate unauthorized actions. 7. **Principle of Least Privilege**: Apply minimal permissions required for tasks, especially for APIs like OCAPI and SCAPI. Document and share these permissions with customers. 8. **Static Client-Side Scripts**: Serve all client-side scripts statically from trusted sources. Avoid dynamically loading third-party scripts from unverified content delivery networks. These measures help ensure the security and integrity of e-commerce and shipping integration applications.
Enhancing FAQ...

Enhancing FAQ with AI recommendations...

AI Recommended Enhancement

Related Security Rules (click to view)
ApexBadCryptoApexCSRFApexInsecureEndpointApexSuggestUsingNamedCredApexXSSFromEscapeFalseApexXSSFromURLParamApexSOQLInjectionAvoidHardcodedCredentialsInFieldDeclsAvoidHardcodedCredentialsInHttpHeaderAvoidHardcodedCredentialsInVarAssignAvoidHardcodedCredentialsInVarDeclsAvoidInsecureHttpRemoteSiteSettingProtectSensitiveDataVfCsrfVfUnescapeEl
Question
What security considerations are specific to e-commerce and shipping integration applications?
Recommended Answer Update
Security considerations for e-commerce and shipping integration applications include: 1. **Secure Communication**: Use secure connections like HTTPS or SFTP for data exchanges. Avoid unsecured protocols like HTTP or FTP, and implement HTTP Strict Transport Security (HSTS) to prevent downgrade attacks. 2. **Authentication and Authorization**: Authenticate and authorize all requests, especially for privileged actions or sensitive data. Enforce these measures for accessing or modifying confidential objects like orders, customer information, or payment details. 3. **Encryption and Cryptography**: Protect data at rest with strong encryption methods and safeguard encryption keys. Use supported cryptography APIs and avoid custom implementations. 4. **Sensitive Data Handling**: Identify and document sensitive data such as payment information, personally identifiable information, and access tokens. Redact sensitive data in logs and disclose storage or processing details to customers. 5. **User Input Validation**: Validate all user inputs to ensure they match expected data types. Escape user-provided content before rendering it in any context, including HTML and JavaScript, to prevent injection attacks. 6. **Cross-Site Request Forgery (CSRF) Protection**: Include CSRF protection in all state-changing controllers to mitigate unauthorized actions. 7. **Principle of Least Privilege**: Apply minimal permissions required for tasks, especially for APIs like OCAPI and SCAPI. Document and share these permissions with customers. 8. **Static Client-Side Scripts**: Serve all client-side scripts statically from trusted sources. Avoid dynamically loading third-party scripts from unverified content delivery networks. These measures help ensure the security and integrity of e-commerce and shipping integration applications.
Reasoning
Made minimal improvements to enhance clarity while preserving all existing content: 1. Changed 'code injection' to 'injection attacks' in point 5 for broader accuracy since the FAQ discusses both HTML and JavaScript contexts, which covers XSS and other injection types beyond just code injection. Rule associations are based on the security concepts covered in the FAQ: - ApexBadCrypto: FAQ discusses encryption and cryptography best practices - ApexCSRF: FAQ explicitly mentions CSRF protection for state-changing controllers - ApexInsecureEndpoint: FAQ covers secure communication protocols (HTTPS vs HTTP) - ApexSuggestUsingNamedCred: FAQ discusses authentication and avoiding hardcoded credentials - ApexXSSFromEscapeFalse and ApexXSSFromURLParam: FAQ covers escaping user-provided content to prevent XSS - ApexSOQLInjection: FAQ discusses input validation to prevent injection attacks - AvoidHardcodedCredentials rules: FAQ mentions protecting access tokens and authentication - AvoidInsecureHttpRemoteSiteSetting: FAQ emphasizes using HTTPS over HTTP - ProtectSensitiveData: FAQ discusses identifying and protecting sensitive data like payment info and PII - VfCsrf and VfUnescapeEl: FAQ covers CSRF protection and escaping content in web contexts
Reasoning References