GitLab Integration
Corridor integrates with GitLab to import your repositories, scan code for security vulnerabilities, and generate guardrails tailored to each project. When merge requests are opened or updated, Corridor automatically reviews the changes and posts findings directly on the MR.The integration currently supports GitLab.com only. Self-hosted GitLab instances are not supported at this time.
What you get
- Automated MR reviews: Every merge request analyzed for security vulnerabilities
- Inline comments: Findings posted directly on the affected code lines
- Finding tracking: Issues persist and track through remediation
- Guardrail generation: Security guardrails tailored to your project’s stack
Prerequisites
- A Corridor account with admin access to your team
- A GitLab.com account with access to the group containing your repositories
Connecting GitLab
Authorize Corridor
You’ll be redirected to GitLab to authorize Corridor. Review the permissions and click Authorize.
Permissions
Corridor requests theapi scope from GitLab. This scope is used for both read operations and to set up automated security reviews on your merge requests. Here’s what that access covers:
| Resource | Usage |
|---|---|
| Groups | List available groups during setup |
| Projects | List repositories in your group for import |
| Repository code | Clone and scan code for security analysis |
| Webhooks | Register per-project webhooks to trigger security reviews on merge requests |
| Merge requests | Read MR diffs for security review and post review comments with findings |
| Project access tokens | Create a bot token per project (“Corridor Security”) to post MR comments |
GitLab does not offer granular OAuth scopes for these individual operations, so
api is the minimum scope required. OAuth tokens are encrypted at rest and automatically refreshed when they expire. Corridor does not store your source code beyond what is needed for analysis.Importing repositories
Troubleshooting
Reviews not appearing
- Verify GitLab is connected in your team settings
- Check that the project was imported from GitLab (not added manually)
- Verify the webhook is registered on the GitLab project:
- Go to your GitLab project → Settings → Webhooks
- Look for a Corridor webhook
- Check Recent events for delivery failures
Permission errors
- Reconnect GitLab from Teams settings
- Ensure your GitLab user has at least Maintainer access to the project
- Verify the project belongs to the connected GitLab group
Webhook delivery failures
- Go to the GitLab project → Settings → Webhooks
- Find the Corridor webhook and click Edit
- Check Recent events for HTTP errors (4xx, 5xx)
- If persistent, contact support@corridor.dev
Next steps
PR Reviews
Learn more about automated reviews
Guardrails
Configure security guardrails for your project