Skip to content

Conversation

@mxj220
Copy link
Contributor

@mxj220 mxj220 commented Jan 22, 2026

What this PR does / why we need it:

Enable creation of Ubuntu 22.04 FIPS VHD. This was blocked by the need for FIPS 140-3 encryption, which is only supported through Azure REST API calls.

Implements instructions listed here https://learn.microsoft.com/en-us/azure/virtual-machines/extensions/agent-linux-fips

Which issue(s) this PR fixes:

Fixes #

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR enables the creation of Ubuntu 22.04 FIPS VHDs by implementing support for FIPS 140-3 encryption through Azure REST API calls. Previously blocked due to the need for FIPS 140-3 encryption (which requires subscription feature registration), this implementation follows the Microsoft documentation for Azure VM extensions with FIPS support.

Changes:

  • Added new fips-helper.sh script with functions to register the FIPS 140-3 compliance feature and create VMs via REST API with FIPS encryption enabled
  • Modified vhd-scanning.sh to detect Ubuntu 22.04 FIPS scenarios and route VM creation through the new REST API approach instead of standard az vm create
  • Updated Go datamodel to use the dynamic LinuxSIGImageVersion for Ubuntu 22.04 FIPS images instead of hardcoded placeholder versions
  • Enabled Ubuntu 22.04 FIPS builds in the release pipeline by setting default values to true

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
vhdbuilder/packer/fips-helper.sh New helper script containing functions for FIPS 140-3 feature registration and REST API-based VM creation
vhdbuilder/packer/vhd-scanning.sh Modified to detect Ubuntu 22.04 FIPS scenario and invoke the new FIPS helper functions; refactored VM_SIZE into a variable for reusability
pkg/agent/datamodel/sig_config.go Updated version field from hardcoded placeholder to dynamic LinuxSIGImageVersion for both 2204 FIPS image templates
pkg/agent/datamodel/sig_config_test.go Added test expectations for the two new Ubuntu 22.04 FIPS distros
.pipelines/.vsts-vhd-builder-release.yaml Enabled Ubuntu 22.04 FIPS builds by changing defaults from false to true

@mxj220 mxj220 enabled auto-merge (squash) January 26, 2026 22:49
@mxj220 mxj220 merged commit b67d770 into main Jan 26, 2026
31 checks passed
@mxj220 mxj220 deleted the markibrahim/enable-fips-2204 branch January 26, 2026 23:54
Copilot AI pushed a commit that referenced this pull request Jan 27, 2026
Co-authored-by: Calvin Shum <calvin197@ymail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants