Courseiva
Azure Apps and Attacks →easyMultiple Choice

GPEN Azure Apps and Attacks Practice Question

A penetration tester is assessing an Azure environment and discovers a function app with an HTTP trigger that does not require authentication. The function app has a system-assigned managed identity with Contributor role on the subscription. What is the most immediate risk?

⚠ Common exam trap

The trap here is focusing on data exposure like source code or logs instead of the direct privilege escalation enabled by the managed identity's high permissions.

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

✓

The function app can be used to perform actions on any resource in the subscription, potentially leading to full subscription compromise.

The unauthenticated HTTP trigger allows anyone to invoke the function. If the function's managed identity has Contributor role on the subscription, an attacker can use the function to execute actions with that identity, effectively gaining Contributor-level access to the entire subscription. This is a severe privilege escalation.

Answer analysis

Option-by-option breakdown

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

  • ✗

    The function app's source code can be downloaded, revealing secrets and connection strings.

    Why it's wrong here

    While source code might contain secrets, the most immediate risk is the ability to perform actions via the managed identity. Downloading code is a separate risk and may require additional permissions. The unauthenticated trigger combined with high-privileged identity directly enables active exploitation.

  • ✗

    The function app's logs can be accessed, revealing sensitive information.

    Why it's wrong here

    Accessing logs might require additional permissions and is not the primary risk. The ability to execute arbitrary actions with Contributor role is far more critical. Log access is typically a read-only operation and does not directly lead to compromise.

  • ✗

    The function app can be used to send emails or messages, leading to spam or phishing.

    Why it's wrong here

    While possible, this is a lesser risk compared to full subscription control. The Contributor role allows much more destructive actions. Sending emails would require additional services and permissions, and is not the most immediate or severe outcome.

  • ✓

    The function app can be used to perform actions on any resource in the subscription, potentially leading to full subscription compromise.

    Why this is correct

    With Contributor role on the subscription, the managed identity can create, modify, or delete any resource. Since the HTTP trigger is unauthenticated, anyone can invoke the function and have it perform actions using that identity. This could allow an attacker to escalate privileges, deploy malicious resources, or delete critical assets.

About these practice questions

Courseiva writes every GPEN question from scratch — 298 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written and reviewed by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

Last reviewed September 2026 · checked against the official GIAC exam blueprint

This GPEN practice question is part of Courseiva's free GIAC 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 GPEN exam.