Free AZ-400 Exam Braindumps
Designing and Implementing Microsoft DevOps Solutions Questions 8–12 (page: 15)

Updated On: 16-Nov-2026

You have a GitHub repository.
You need to ensure that all the code in the repository is scanned for vulnerabilities.
What should you use?

  1. Dependabot alerts
  2. branch protection rules
  3. CodeQL actions
  4. GitHub Advisory Database databases

Answer(s): A

Explanation:

Identifying vulnerabilities in your project's dependencies with Dependabot alerts
Dependabot generates Dependabot alerts when known vulnerabilities are detected in dependencies that your project uses.


Reference:

https://docs.github.com/en/code-security/dependabot/dependabot-alerts



HOTSPOT (Drag and Drop is not supported)
You have an Azure subscription and a GitHub Actions workflow named workflow1.
You deploy the following Bicep file to the subscription by using workflow1.

For each of the following statements, select Yes if the statement is true. Otherwise, select No.
Note: Each correct selection is worth one point.
Hot Area:

  1. See Explanation section for answer.

Answer(s): A

Explanation:



Box 1: No
No - An Azure key vault will be deployed.
No, an Azure Key Vault will not be deployed by this Bicep file.
existing Keyword: The Bicep code uses the existing keyword in the resource declaration for kv.
Reference Only: This keyword tells Azure Resource Manager that the Key Vault already exists in your subscription.
No Creation: Azure will only look up the existing Key Vault to fetch data from it, rather than provisioning a new one.
Box 2: No
No - The logs for workflow1 will contain the admin password for Microsoft SQL Server.
No, the logs for the GitHub Actions workflow will not contain the admin password.
Key Vault Secrets are Masked: Azure Resource Manager (ARM) and GitHub Actions automatically treat values retrieved via the .getSecret() function as sensitive data.Bicep Parameter Protection: Azure automatically masks outputs and secure parameters in the deployment logs.
GitHub Runner Redaction: Even if the value were accidentally printed to the console, GitHub Actions automatically redacts known secrets and replaces them with asterisks (***).
Box 3: Yes
Yes - The admin password for Microsoft SQL Server will be retrieved from an Azure key vault.
What the Code Actually Does:
Looks Up Key Vault: It references a Key Vault named kvName inside the resource group kvResourceGroup.
Retrieves a Secret: It pulls a secure string (vmAdminPassword) from that existing Key Vault using the kv.getSecret() function.
Deploys SQL Module: It passes that retrieved secret as the adminPassword parameter into a separate module file named ./sql.bicep.


Reference:

https://www.mdpi.com/1999-5903/17/8/359
https://www.jetbrains.com/help/teamcity/cloud/git.html



HOTSPOT (Drag and Drop is not supported)
You have a GitHub repository named Repo1 and an app named App1. Repo1 stores the source code for App1.
You need to perform the following tests:
-Test1: Run a ZAP spider against App1 for one minute and wait for passive scanning to complete. The test must NOT perform active attacks.
-Test2: Run a ZAP spider against App1, and when complete, execute an AJAX spider scan.
Which GitHub action should you use for each test? To answer, select the appropriate options in the answer area.
Note: Each correct selection is worth one point.
Hot Area:

  1. See Explanation section for answer.

Answer(s): A

Explanation:



Box 1: ZAP Baseline Scan
Test1: Run a ZAP spider against App1 for one minute and wait for passive scanning to complete. The test must NOT perform active attacks.
ZAP - Baseline Scan
The ZAP Baseline scan is a script that is available in the ZAP Docker images.
It runs the ZAP spider against the specified target for (by default) 1 minute and then waits for the passive scanning to complete before reporting the results.
This means that the script doesn’t perform any actual ‘attacks’ and will run for a relatively short period of time (a few minutes at most).
By default, it reports all alerts as WARNings but you can specify a config file which can change any rules to FAIL or IGNORE.
This script is intended to be ideal to run in a CI/CD environment, even against production sites.
Box 2: ZAP Full Scan
Test2: Run a ZAP spider against App1, and when complete, execute an AJAX spider scan.
ZAP Action Full Scan
A GitHub Action for running the ZAP Full Scan to perform Dynamic Application Security Testing (DAST).
The ZAP full scan action runs the ZAP spider against the specified target (by default with no time limit) followed by an optional ajax spider scan and then a full active scan before reporting the results. The alerts will be maintained as a GitHub issue in the corresponding repository.
Incorrect:
* ZAP - API Scan
The ZAP API scan is a script that is available in the ZAP Docker images.
It is tuned for performing scans against APIs defined by OpenAPI, SOAP, or GraphQL via either a local file or a URL.
It imports the definition that you specify and then runs an Active Scan against the URLs found. The Active Scan is tuned to APIs, so it doesn’t bother looking for things like XSSs.


Reference:

https://www.zaproxy.org/docs/docker/baseline-scan https://github.com/zaproxy/action-full-scan https://www.zaproxy.org/docs/docker/api-scan



You use GitHub Enterprise to manage source code and deployments.
From GitHub Actions, you create a reusable workflow named workflow1.
You need to ensure that the secrets defined in the calling workflow are passed to workflow1.
What should you include in the YAML file for the calling workflow?





Answer(s): A

Explanation:

Create reusable workflows in GitHub Actions
Workflows that call reusable workflows in the same organization or enterprise can use the inherit keyword to implicitly pass the secrets.
Example:
jobs:
call-workflow-passing-data:
uses: octo-org/example-repo/.github/workflows/reusable-workflow.yml@main with:
config-path: .github/labeler.yml secrets: inherit
Note: Passing named secrets
To pass named inputs to a called workflow, use the with keyword in a job. Use the secrets keyword to pass named secrets. For inputs, the data type of the input value must match the type specified in the called workflow (either boolean, number, or string).
jobs:
call-workflow-passing-data:
uses: octo-org/example-repo/.github/workflows/reusable-workflow.yml@main with:
config-path: .github/labeler.yml secrets:
envPAT: ${{ secrets.envPAT }}


Reference:

https://resources.github.com/learn/pathways/automation/intermediate/create-reusable-workflows-in-github-acti ons/



HOTSPOT (Drag and Drop is not supported)
You have a GitHub project that is used to develop a container app named App1.
You have a GitHub Actions workflow that includes the following.

For each of the following statements, select Yes if the statement is true. Otherwise, select No.
Note: Each correct selection is worth one point.
Hot Area:

  1. See Explanation section for answer.

Answer(s): A

Explanation:



Box 1: Yes
Yes - App1 will be deployed to an Azure
The application will be deployed to an Azure Container Registry (ACR) as part of the build and push process, which prepares it for deployment to an Azure hosting service like Azure Container Apps or Azure Kubernetes Service (AKS).
Correct Target Services
Azure Container Registry (ACR): The immediate target of this specific workflow. The command docker push registry.azurecr.io/app1... uploads the built container image to your private Azure registry host (registry.azurecr.io).
Azure Container Apps / Azure App Service: Once the image is safely stored in ACR, Azure continuous deployment features pull that image to run your containerized application.
Box 2: No
No - The secrets will be written to the log in plain text.
No, the secrets will not be written to the log in plain text.
GitHub Actions Secret Masking
Automatic Redaction: GitHub automatically masks any environment variables or secrets configured via GitHub Actions Secrets.
Log Masking: Masked values are replaced with asterisks (***) in the runner logs.
Build Outputs: Even though the docker-login step uses the secrets directly, GitHub intercepts the standard output and standard error to hide these values.
Box 3: No
No - The :latest tag will be applied to the container image.
No, the :latest tag will not be applied to the container image based on this workflow code.
Explicit Tagging: Docker only applies tags that you explicitly define in the command.
Sha Tag Only: The script only specifies registry.azurecr.io/app1:${{ github.sha }}.
No Automatic Latest: Docker does not automatically generate or push a :latest tag unless you tell it to do so.
How to add the latest tag
To apply and push the :latest tag alongside the commit SHA, update your run step to include a second tag and push command:
- run: |
docker build . -t registry.azurecr.io/app1:${{ github.sha }} -t registry.azurecr.io/app1:latest docker push registry.azurecr.io/app1:${{ github.sha }}
docker push registry.azurecr.io/app1:latest


Reference:

https://docs.doppler.com/docs/github-actions https://learn.microsoft.com/en-us/answers/questions/2116172/azure-container-apps-not-getting-updated-imag e-tag



Viewing page 15 of 81
Viewing questions 71 - 75 out of 398 questions


Post your Comments and Discuss Microsoft AZ-400 exam prep with other Community members:

AI Tutor AI Tutor 👋 I’m here to help!