Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

Gitea: Webhook Authorization Header Returned in Plaintext via API (CVE-2026-58511)

0
Low
Published: 07/21/2026 (07/21/2026, 21:52:49 UTC)
Source: GCVE Database
Product: code.gitea.io/gitea

Description

Gitea versions prior to 1.27.0 contain a vulnerability where the webhook authorization header, which is stored encrypted in the database, is decrypted and returned in plaintext via certain API endpoints. This allows any repository admin to view sensitive authorization headers (such as Bearer tokens, Basic auth credentials, and API keys) set by other admins. The issue affects multiple API endpoints that return webhook details and requires repository or site admin privileges to access. The vulnerability undermines the encryption-at-rest protection by exposing secrets in API responses.

CVSS v3.1

Attack Vector
Network
Attack Complexity
Low
Privileges Required
High
User Interaction
None
Scope
Unchanged
Confidentiality
Low
Integrity
None
Availability
None
CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:L/I:N/A:N

Affected software

Goghsa
code.gitea.io/gitea
Affected versions
<1.27.0

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 07/22/2026, 00:38:43 UTC

Technical Analysis

In Gitea versions before 1.27.0, the function ToHook() decrypts the webhook's HeaderAuthorizationEncrypted field and includes the plaintext authorization header in API responses. This behavior exposes sensitive authorization headers to any repository admin who queries webhook information via endpoints like GET /api/v1/repos/{owner}/{repo}/hooks. Although the authorization header is encrypted in storage using the server's SecretKey, the API response reveals the decrypted value, effectively converting a write-only secret into a readable credential. This affects multiple endpoints requiring admin privileges and risks cross-admin secret exposure and potential external service compromise.

Potential Impact

The vulnerability allows repository administrators to access plaintext webhook authorization headers set by other admins, exposing sensitive credentials such as Bearer tokens, Basic authentication credentials, and API keys. This can lead to credential harvesting if an admin's Gitea token is compromised and may result in unauthorized access to external services integrated via webhooks. The exposure undermines the intended encryption-at-rest protection of these secrets, increasing the risk of secret leakage within shared repositories.

Mitigation Recommendations

Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. The suggested fix is to make the authorization header write-only by returning a masked or redacted version or a boolean flag indicating the presence of an authorization header instead of the plaintext value. Until an official fix is available, restrict repository admin access to trusted users and avoid sharing sensitive authorization headers in webhooks.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Gcve Source
db.gcve.eu
Osv Id
GHSA-3r5c-2xxx-h872
Osv Schema Version
1.4.0
Aliases
["CVE-2026-58511"]
Ecosystems
["Go"]
Database Specific Severity
LOW
Cvss Version
3.1

Threat ID: 6a600aa29c2644c7f8fdfcb5

Added to database: 07/22/2026, 00:11:14 UTC

Last enriched: 07/22/2026, 00:38:43 UTC

Last updated: 07/22/2026, 03:46:49 UTC

Views: 4

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses