Skip to content

fix(security): ensure PR followers have access to PR#47

Merged
daabr merged 1 commit into
mainfrom
follower-access
Apr 19, 2026
Merged

fix(security): ensure PR followers have access to PR#47
daabr merged 1 commit into
mainfrom
follower-access

Conversation

@daabr

@daabr daabr commented Apr 19, 2026

Copy link
Copy Markdown
Member

...before adding them to the PR channel (so Slack won't breach SCM permissions).

@codecov

codecov Bot commented Apr 19, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 17 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
pkg/bitbucket/workflows/pullrequest.go 0.00% 17 Missing ⚠️

📢 Thoughts on this report? Let us know!

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds a security guardrail to Bitbucket PR channel creation so that “followers of the PR author” are only invited to the PR’s Slack channel if they can actually access the PR in Bitbucket, preventing unintended exposure.

Changes:

  • Filters PR author followers through an access check before inviting them to the PR Slack channel.
  • Introduces helper functions to (a) parse repo full name and (b) verify access via a Bitbucket PR fetch using the follower’s credentials.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread pkg/bitbucket/workflows/pullrequest.go
Comment thread pkg/bitbucket/workflows/pullrequest.go
Comment thread pkg/bitbucket/workflows/pullrequest.go
@daabr daabr merged commit e8efbcc into main Apr 19, 2026
9 checks passed
@daabr daabr deleted the follower-access branch April 19, 2026 04:32
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.

2 participants