microsoft / microsoft/security-devops-azdevops

Allow Direct Path Specification for Bicep Files in MicrosoftSecurityDevOps@1 Task

Open
#129 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
86
Forks
22
PR merge metrics
No merged PRs in 30d

Description

I am using the MicrosoftSecurityDevOps@1 task in my Azure pipeline to scan Infrastructure as Code (IaC) files. My repository contains multiple Bicep modules, each located in their own subfolders. Here is a snippet of my pipeline configuration:
parameters:

  • name: serviceConnection
    type: string
  • name: resourceGroup
    type: string
  • name: bicepFile
    type: string
  • name: parametersFile
    type: string

jobs:

  • job:
    displayName: "Scan IaC Templates"
    pool:
    vmImage: windows-latest
    steps:
    • checkout: azure.infra.bicep
    • task: MicrosoftSecurityDevOps@1
      displayName: MSDO IAC
      inputs:
      categories: 'IaC'

The folder structure of my repository is as follows:
repo_name/
└── modules/
└── module-name/
└── module-name.bicep

Issue: Currently, there is no option to specify a direct path to a specific Bicep file within the MicrosoftSecurityDevOps@1 task. As a result, the tool attempts to scan absolutely all files being checked out, while I need to scan only the Bicep file specified in my parameters. This limitation makes it challenging to target individual Bicep files for scanning in repositories with complex structures and multiple modules.

Proposal: Introduce an option to specify a direct path to a specific Bicep file in the MicrosoftSecurityDevOps@1 task. This feature would allow for more targeted scanning of individual Bicep files.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start from the MicrosoftSecurityDevOps@1 task input handling and its IaC/Bicep scan entry point. Trace how checked-out files are selected, then define the requested direct-path input using the pipeline's bicepFile parameter. Done means the task can scan one specified Bicep file without scanning unrelated checked-out files.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure
Domain
ci-cd, devops
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.