Join our Newsletter — 33% off our NHI Course
Home› FAQ› Architecture & Implementation› How should security teams protect PII when database…
Architecture & Implementation

How should security teams protect PII when database encryption at rest is not enough?

← Back to all FAQ
By NHI Mgmt Group Editorial Team Updated November 19, 2026 Domain: Architecture & Implementation

Move the protection boundary into the application so sensitive values are encrypted before they reach the database. Store only opaque object references, keep the key context tied to the tenant, and restrict decryption to the exact workflows that truly need plaintext. That design limits the damage from SQL access, exports, and internal query abuse.

Why database encryption at rest is not the full answer for PII

Encryption at rest protects the storage layer, but it does not stop every place where PII can be exposed. If the database can decrypt values for normal queries, then a user or service with sufficient SQL access can often still retrieve plaintext, and exports or replication paths can carry that plaintext onward. The control boundary has to move closer to the application decision point.

That is why application-layer protection usually focuses on encrypting sensitive values before they are written and only exposing plaintext inside tightly defined workflows. The point is not simply to “add another cipher”, it is to reduce the number of actors, paths, and query surfaces that ever see usable PII.

For teams comparing protection models, the practical distinction is explained well in Client-Side vs Server-Side Encryption and Encryption at Rest vs In Transit vs In Use, because the failure modes are different once decryption happens outside the storage tier.

How to reduce exposure without breaking application workflows

The strongest pattern is to keep the database as an index and persistence layer, not the place where business logic needs broad access to raw PII. Store opaque references where possible, separate the data needed for routing or lookup from the data needed for disclosure, and bind decryption to the narrow workflow that genuinely requires the plaintext. That makes ordinary reporting, ad hoc SQL, and bulk export far less useful to an attacker or insider.

Key context matters as much as encryption strength. Tenant-aware keying and strict separation between environments make it harder for one compromise to become a cross-tenant or cross-environment event. If a shared key can open many records or many customers, you have reduced the problem of confidentiality, not solved it.

Teams that want a deeper implementation baseline can use Database and Storage Encryption Guide for database-specific choices, and Encryption Guide for the broader set of encryption trade-offs, including field-level and envelope designs.

What security teams should validate before calling the design complete

Test the design against the actual abuse cases that matter: SQL read access, direct exports, service account misuse, backup access, analytics replication, and support workflows that can retrieve plaintext. If any of those paths can reveal PII without a strong business justification, the protection boundary is still too loose.

Also verify that key custody and decryption permissions are operationally separated. A design is only effective when the systems that can store PII cannot automatically decrypt it for every downstream caller. The database may remain trustworthy, but the trust should be limited to the exact workflows that need it.

For a control-oriented view of hardening and monitoring, Database Security Guide and CIS Control 3 Data Protection Guide both reinforce the need to treat data access, auditability, and encryption as linked controls rather than separate checkboxes.

Risk and Threat Considerations

When encryption only exists at the database layer, the main risk is that authorised access to the database still becomes authorised access to readable PII. That expands the blast radius of SQL injection, overprivileged query tools, compromised service accounts, and internal misuse, especially when exports or replicas preserve the same readable form.

Failure mechanism: Decryption happens too late in the data flow, so any actor that can query or export the database can often obtain plaintext, even if storage is encrypted at rest.

Impact: Sensitive records can be exposed at scale through routine operational paths, which increases breach severity, complicates segmentation of duties, and weakens the value of storage-only encryption during incident response.

Standards & Framework Alignment

This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.

NIST SP 800-53 Rev 5 and CIS Controls v8 set the technical controls, while ISO/IEC 27001:2022 defines the regulatory obligations.

FrameworkControl / ReferenceRelevance
NIST SP 800-53 Rev 5SC-28 — Protection of Information at RestPII protection at rest needs stronger application-layer controls.
AC-6 — Least PrivilegePlaintext access should be confined to only the workflows that need it.
AU-2 — Audit EventsThe design needs logging of decrypt and export paths that can reveal PII.
Recommendation — Use SC-28 to protect sensitive data before storage and limit readable exposure. Apply AC-6 to restrict decryption and query access to the minimum required. Log decryption and export activity so plaintext access is attributable and reviewable.
ISO/IEC 27001:2022A.8.24 — Use of cryptographyApplication-layer encryption and key handling are central to protecting PII.
Recommendation — Define cryptographic use and key handling rules for sensitive records.
CIS Controls v8CIS-3 — Data ProtectionThe subject is about reducing exposure of sensitive data beyond storage encryption.
Recommendation — Segment sensitive data handling and encryption by business need and exposure.

Practitioner Guidance

What to prioritise: Put protection where disclosure decisions are made. If a workflow does not need plaintext, redesign it to consume opaque tokens or minimally exposed fields rather than decrypting full records.

What to verify: Confirm that decryption is limited to the smallest possible set of services, tenants, and functions, and that backups, analytics jobs, support tooling, and admin queries cannot bypass that boundary.

Common mistake: Treating database encryption as a substitute for application design. The right question is not whether the database is encrypted, but whether the system still makes plaintext broadly available after the database accepts the record.

Practitioner takeaway: If a compromise of SQL access would still expose usable PII, the control is not strong enough, regardless of how well the data is encrypted on disk.

Free weekly newsletter

Subscribe to the NHI & AI Identity Journal

The latest on NHI and Agentic AI security – articles, research, breaches, news and events every week.

Bonus 33% off our NHI Course when you subscribe.

NHIMG Editorial Note
Reviewed and updated by the NHIMG editorial team on November 19, 2026.
NHI Mgmt Group — the #1 independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org