NIS2 Encryption Requirements: What Enterprises Must Implement
Mar 12, 2025
ArticleNIS2 encryption and key-management expectations for essential and important entities, what supervisors look for beyond “data is encrypted.”
Read article
Implement Salesforce BYOK so CRM and pipeline data stay under keys Salesforce cannot use alone, without blocking the sales organisation.
For enterprises storing sensitive customer data in Salesforce, the question of encryption key ownership has become a critical compliance and security concern. Salesforce encryption BYOK (Bring Your Own Key) offers organizations the ability to maintain cryptographic control over their CRM data, even when that data resides in Salesforce's multi-tenant cloud infrastructure. This capability has moved from a security luxury to a regulatory necessity, particularly for organizations operating under GDPR, DORA, NIS2, or industry-specific frameworks like HIPAA and TISAX.
The fundamental challenge is straightforward: when your encryption keys are generated, stored and managed by your cloud provider, you've effectively delegated the security of your most sensitive data to a third party. For regulated industries, financial services, healthcare, automotive and government, this delegation creates audit gaps, compliance risks and potential exposure to foreign jurisdiction data access requests. Salesforce external key management addresses this gap by allowing enterprises to retain ultimate authority over the cryptographic keys protecting their CRM data.
This guide examines the technical architecture, compliance implications and operational considerations for implementing BYOK and Cache-Only Key solutions within Salesforce Shield Platform Encryption. We'll provide the technical depth that CISOs and security architects need to make informed decisions about their CRM data sovereignty strategy.
Salesforce provides encryption capabilities out of the box, but the default implementation leaves significant security and compliance gaps that enterprise security teams cannot ignore.
Salesforce's standard encryption uses keys that are generated and stored within Salesforce's infrastructure. While this provides protection against certain threat vectors, such as physical theft of storage media, it does not address the fundamental concern of provider access. Salesforce administrators, support personnel and potentially law enforcement in Salesforce's operating jurisdictions can theoretically access the encryption keys protecting your data.
For organizations subject to European data protection regulations, this creates a direct conflict with the principle of data sovereignty. The Schrems II ruling invalidated the Privacy Shield framework precisely because US-based providers could be compelled to provide access to data under the CLOUD Act, regardless of where that data is physically stored.
When auditors examine your Salesforce security posture, they will ask a critical question: "Who controls the encryption keys?" If the answer is "Salesforce," you face several problems:
With provider-managed keys, you cannot demonstrate independent control. Your security posture is only as strong as Salesforce's internal access controls, controls you cannot audit or verify.
Salesforce employs thousands of personnel globally. While the company maintains robust security practices, insider threats remain a statistical reality in any large organization. A 2024 Verizon Data Breach Investigations Report found that insider threats accounted for 19% of breaches, with privileged access abuse being a primary vector.
When Salesforce holds your encryption keys, a compromised insider at Salesforce becomes a threat to your data. External key management eliminates this risk by ensuring that Salesforce personnel, regardless of their access level, cannot decrypt your data without your explicit participation.
The extraterritorial reach of the US CLOUD Act means that a US court order can compel Salesforce to produce data stored on servers anywhere in the world. For European enterprises, this creates an irreconcilable conflict with GDPR's data protection requirements.
With Salesforce BYOK encryption properly implemented, even if Salesforce is compelled to hand over encrypted data, they cannot provide the keys to decrypt it. This creates a technical safeguard that complements legal and contractual protections.
Salesforce offers two distinct approaches to customer-controlled encryption: Bring Your Own Key (BYOK) and Cache-Only Key. Understanding the differences is essential for selecting the right model for your security requirements.
In the BYOK model, you generate your tenant secret outside of Salesforce and upload it to the platform. Salesforce combines your tenant secret with a Salesforce-generated master secret to create the data encryption key that protects your information.
Key characteristics of BYOK:
| Aspect | BYOK Behavior |
|---|---|
| Key Generation | Customer-generated tenant secret |
| Key Storage | Tenant secret stored in Salesforce HSM |
| Key Derivation | Combined with Salesforce master secret |
| Revocation | Destroys tenant secret; requires Salesforce support for recovery |
| Offline Access | Salesforce can access encrypted data (with derived key) |
BYOK provides significant improvement over purely Salesforce-managed encryption because you control the tenant secret generation process. However, because the derived data encryption key exists within Salesforce's infrastructure, Salesforce technically retains the ability to decrypt your data during normal operations.
The Salesforce Cache-Only Key model goes further by ensuring that your key material never persists in Salesforce's infrastructure. Instead, your external key management system provides keys on demand and Salesforce caches them in memory only for the duration of active use.
Key characteristics of Cache-Only Key:
| Aspect | Cache-Only Key Behavior |
|---|---|
| Key Generation | Customer-generated and managed externally |
| Key Storage | Never persisted in Salesforce; memory-only cache |
| Key Derivation | Key material fetched from external KMS via callout |
| Revocation | Immediate by revoking external key service access |
| Offline Access | Salesforce cannot access data without external key service |
Cache-Only Key provides the strongest form of CRM data sovereignty available in Salesforce. If you revoke access to your external key service, Salesforce immediately loses the ability to decrypt your data, no support ticket required, no grace period.
Choose BYOK when:
Choose Cache-Only Key when:
For organizations in regulated industries, particularly European financial services, healthcare and automotive, Cache-Only Key typically represents the appropriate choice for maximum data sovereignty.
Salesforce Shield Platform Encryption is the enterprise encryption framework that enables both BYOK and Cache-Only Key implementations. Understanding its architecture is essential for proper deployment.
Shield Platform Encryption operates on a hierarchical key structure:
This hierarchy provides defense in depth. Compromising a single per-record key does not expose all encrypted data and the separation between master and tenant secrets means neither party alone can derive the data encryption key.
Shield Platform Encryption supports encryption for:
Not all field types support encryption. Formula fields, auto-number fields and certain system fields cannot be encrypted. Your implementation team must map sensitive data fields to encryptable field types during the planning phase.
Salesforce Shield offers two encryption schemes:
Probabilistic Encryption provides maximum security by generating unique ciphertext for identical plaintext values. The same customer name encrypted twice produces different ciphertext. This prevents pattern analysis attacks but limits certain functionality, you cannot filter or group by encrypted fields.
Deterministic Encryption produces consistent ciphertext for identical plaintext values, enabling filtering, grouping and case-insensitive matching on encrypted data. However, this consistency creates a theoretical vulnerability to frequency analysis on high-cardinality fields.
For most enterprise deployments, probabilistic encryption is appropriate for highly sensitive fields (social security numbers, financial data), while deterministic encryption suits fields requiring query functionality (email addresses for duplicate matching).
Shield Platform Encryption requires the Salesforce Shield add-on license. This license also includes Event Monitoring and Field Audit Trail capabilities. For organizations implementing comprehensive security programs, these additional features often justify the Shield investment beyond encryption alone.
Cache-Only Key functionality requires Shield Platform Encryption plus additional configuration for external key service integration.
Implementing Salesforce external key management requires connecting your key management system (KMS) to Salesforce's encryption infrastructure. This integration follows a standardized architecture but demands careful planning.
The integration architecture for Cache-Only Key involves:
When Salesforce needs to encrypt or decrypt data, it makes an authenticated callout to your key service, retrieves the key material, uses it for the cryptographic operation and discards the key from memory when no longer needed.
Before beginning implementation, ensure you have:
Step 1: Configure Your External KMS
Your KMS must expose an HTTPS endpoint that accepts key fetch requests and returns key material in Salesforce's expected format. The response must include:
DuoKey's Salesforce integration provides a pre-built connector that handles this protocol, eliminating custom development requirements.
Step 2: Create Named Credential in Salesforce
Navigate to Setup > Security > Named Credentials and create a new credential:
Step 3: Upload Certificates
Upload the client certificate that Salesforce will present to your KMS and configure your KMS to trust Salesforce's certificate chain.
Step 4: Configure Cache-Only Key Service
In Setup > Security > Platform Encryption > Key Management:
Step 5: Test the Integration
Use Salesforce's built-in testing tools to verify:
Step 6: Enable Encryption on Fields
Once the key service is operational, enable encryption on your sensitive fields through Setup > Security > Platform Encryption > Encryption Policy.
Cache-Only Key creates a runtime dependency on your external key service. If your KMS is unavailable, Salesforce cannot decrypt protected data. This has significant implications:
Salesforce BYOK and Cache-Only Key in particular, directly addresses several GDPR compliance concerns raised by the Schrems II ruling.
With Cache-Only Key properly configured, you can demonstrate to regulators that:
Maintain the following documentation for GDPR audits:
Encryption introduces latency into Salesforce operations. Understanding and managing this impact is essential for successful adoption.
For Cache-Only Key, each encryption/decryption operation typically adds:
Regular key rotation is a compliance requirement and a security best practice.
| Data Type | Recommended Rotation Frequency |
|---|---|
| Highly sensitive data (financial, health) | Quarterly |
| Standard personal data | Annually |
| Less sensitive operational data | Every 2 years |
Key rotation does not cause service interruption in Salesforce, the platform manages the transition in the background while normal operations continue.
Salesforce BYOK encryption and Cache-Only Key in particular, represents the most robust CRM data sovereignty architecture available on the platform. For European organisations subject to GDPR, DORA, or NIS2, it is increasingly not an option but a necessity to demonstrate adequate control over sensitive personal and financial data.
The key to success lies in choosing the right architecture (BYOK vs Cache-Only Key based on your threat model), implementing a high-availability external key management infrastructure and rigorously documenting controls for audits. DuoKey provides a pre-built connector for Salesforce Cache-Only Key that significantly simplifies this deployment while satisfying the most stringent data sovereignty requirements of European regulators.
Written by
DuoKey Security Team
Related Resources
Tell us where control is difficult today. We will help you identify a practical next step.