CVE-2025-47943: Gogs stored XSS in PDF renderer

Published Jun 24, 2025
·
Updated

Summary

A stored XSS is present in Gogs which allows client-side Javascript code execution.

Details

Gogs Version: docker images REPOSITORY TAG IMAGE ID CREATED SIZE gogs/gogs latest fe92583bc4fe 10 hours ago 99.3MB

Application version: 0.14.0+dev

Local setup using: bash Pull image from Docker Hub. docker pull gogs/gogs

Create local directory for volume. sudo mkdir -p /var/gogs

Use docker run for the first time. docker run --name=gogs -p 10022:22 -p 10880:3000 -v /var/gogs:/data gogs/gogs

The vulnerability is caused by the usage of a vulnerable and outdated component: pdfjs-1.4.20 under public/plugins/. Read more about this vulnerability at codeanlabs - CVE-2024-4367.

PoC

1. Upload the Proof of Concept file hosted at https://codeanlabs.com/wp-content/uploads/2024/05/pocgeneralizedCVE-2024-4367.pdf in a repository. 2. Click on the file to be previewed.

!poc

Credits

Edoardo Ottavianelli

Other sources

Gogs is an open source self-hosted Git service. In application version 0.14.0+dev and prior, there is a stored cross-site scripting (XSS) vulnerability present in Gogs, which allows client-side Javascript code execution. The vulnerability is caused by the usage of a vulnerable and outdated component: pdfjs-1.4.20 under public/plugins/. This issue has been fixed for gogs.io/gogs in version 0.13.3.

MITRE

Affected Software

4 affected componentsFixes available
Gogs Gogs<0.14.0+dev
Gogs Gogs>=0.13.3
go/gogs.io/gogs<0.13.3-0.20250608224432-110117b2e5e5
0.13.3-0.20250608224432-110117b2e5e5
go/github.com/gogs/gogs<0.13.3-0.20250608224432-110117b2e5e5
0.13.3-0.20250608224432-110117b2e5e5

Event History

Jun 24, 2025
CVE Published
via MITRE·03:48 AM
Data Sourced
via MITRE·03:48 AM
DescriptionSeverityWeakness
Data Sourced
via NVD·04:15 AM
DescriptionSeverityWeakness
Jun 26, 2025
Advisory Published
via GitHub·04:54 PM
Data Sourced
via GitHub·04:54 PM
DescriptionSeverityWeaknessAffected Software
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2025-47943?

CVE-2025-47943 is a stored cross-site scripting (XSS) vulnerability that allows for client-side Javascript code execution.

2

How do I fix CVE-2025-47943?

To fix CVE-2025-47943, upgrade Gogs to version 0.14.0 or later.

3

Which versions of Gogs are affected by CVE-2025-47943?

Gogs versions from 0.13.3 up to, but not including, 0.14.0+dev are affected by CVE-2025-47943.

4

What impact does CVE-2025-47943 have on my Gogs installation?

CVE-2025-47943 can allow attackers to execute arbitrary client-side scripts in the context of the user’s session.

5

Is there a workaround for CVE-2025-47943 if I cannot upgrade Gogs?

There are no documented workarounds for CVE-2025-47943; upgrading to a patched version is recommended.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203