Courseiva

DP-300 Implement a secure environment Practice Question

You are deploying Azure SQL Database for a multi-tenant application. Each tenant's data must be isolated. You need to ensure that tenants cannot access each other's data even if there is a SQL injection vulnerability. Which security feature should you implement?

⚠ Common exam trap

A common mix-up: candidates confuse data-at-rest encryption (TDE or Always Encrypted) with access control, mistakenly believing encryption alone can prevent unauthorized row access during a SQL injection attack.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

Implement row-level security (RLS) with a security policy that filters rows by tenant ID.

Row-level security (RLS) is the correct choice because it enforces data isolation at the database engine level by filtering rows based on a tenant ID predicate. Even if a SQL injection vulnerability allows an attacker to execute arbitrary queries, RLS ensures that only rows belonging to the attacker's tenant are returned, preventing cross-tenant data access. This is a defense-in-depth measure that works regardless of application-layer flaws.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✗

    Use Always Encrypted to encrypt sensitive columns.

    Why it's wrong here

    Always Encrypted protects column values from the database engine and administrators, but a successful injection still reads any decrypted rows the application's connection can reach. It is the right choice for protecting sensitive columns from privileged insiders. Row-level security enforces tenant predicates inside the engine, blocking cross-tenant reads.

  • ✗

    Configure Azure SQL Database auditing to monitor cross-tenant access.

    Why it's wrong here

    Auditing only records activity after it occurs; it cannot block a query that a SQL injection has already crafted. It is tempting because auditing is genuinely used for compliance evidence and forensic review of suspicious access. Row-level security, scoped per tenant, filters rows before they are returned regardless of the injected predicate.

  • ✗

    Enable Transparent Data Encryption (TDE) on the database.

    Why it's wrong here

    TDE encrypts data and backups at rest, yet the engine decrypts transparently for every authorised connection, so an injected query still returns other tenants' rows. It is genuinely for meeting at-rest encryption compliance. Row-level security applies tenant filters within the query, preventing cross-tenant access even through injection.

  • ✓

    Implement row-level security (RLS) with a security policy that filters rows by tenant ID.

    Why this is correct

    Row-level security with a security policy filtering by tenant ID enforces isolation inside the database engine itself, so a SQL injection cannot return another tenant's rows regardless of query construction. This satisfies the requirement that tenants cannot access each other's data.

About these practice questions

One of 574 original DP-300 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This DP-300 practice question is part of Courseiva's free Microsoft certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the DP-300 exam.