ci: fix platform-api cloud-release webhook trigger and signature - #3311
Merged
renuka-fernando merged 1 commit intoAug 25, 2026
Conversation
The Azure DevOps Incoming WebHook service connection reads the HMAC signature from the `x-webhook-checksum` header and expects the bare hex digest, not GitHub's `X-Hub-Signature: sha1=<hex>` format. The mismatched header name caused the webhook to reject requests with `RequiredHeaderSignatureNotFound` (HTTP 500). Send the checksum under the correct header and drop the `sha1=` prefix so Azure can verify the payload. Signed-off-by: Renuka Fernando <renukapiyumal@gmail.com>
renuka-fernando
requested review from
AnuGayan,
Arshardh,
CrowleyRajapakse,
HeshanSudarshana,
HiranyaKavishani,
Krishanx92,
PasanT9,
RakhithaRR,
Tharsanan1,
VirajSalaka,
ashera96,
chamilaadhi,
dushaniw,
hisanhunais,
malinthaprasan,
pubudu538,
senthuran16,
tgtshanika,
tharikaGitHub and
tharindu1st
as code owners
August 25, 2026 10:22
Contributor
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This was referenced Aug 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
The
Platform API Cloud Releaseworkflow triggers the Azure DevOps build by POSTing a signed payload to an Incoming WebHook service connection. Two problems prevented it from working:pull_request: [closed], but apull_requestrun for a PR opened from a fork receives no repository secrets, soAZURE_WEBHOOK_URL/AZURE_WEBHOOK_SECRETwere empty and the job failed the pre-flight secret check.RequiredHeaderSignatureNotFound(HTTP 500) because the workflow sent the HMAC under GitHub'sX-Hub-Signature: sha1=<hex>convention, while the Azure service connection reads it from thex-webhook-checksumheader and expects the bare hex digest.Approach
pull_request: [closed]topushon the release branches (main,platform-api/v0.10.x). A merge produces a push, which runs with full secret access and executes the workflow version on the pushed branch.if:guard and thepull_request-specificBRANCH/COMMITexpressions in favour ofgithub.ref_name/github.sha.x-webhook-checksumheader, and drop thesha1=prefix so the value is the bare hex digest Azure expects.Related Issues
N/A
Automation tests
N/A — CI workflow change only. Verified against the Azure DevOps webhook with a manual
curlmatching the header/checksum format, and via a manualworkflow_dispatchrun.Security checks
secrets.AZURE_WEBHOOK_SECRET.Checklist