Cross-site Request Forgery (CSRF) Affecting wger package, versions [0,]


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept
EPSS
0.09% (1st percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-PYTHON-WGER-21693644
  • published24 Oct 2026
  • disclosed7 Oct 2026
  • creditUnknown

Introduced: 7 Oct 2026

NewCVE-2026-45161  (opens in a new tab)
CWE-352  (opens in a new tab)

How to fix?

A fix was pushed into the master branch but not yet published.

Overview

Affected versions of this package are vulnerable to Cross-site Request Forgery (CSRF) via the trainer_login view in wger/core/views/user.py, which accepts GET requests and calls django_login() without any CSRF protection. Because Django's CsrfViewMiddleware only enforces token validation on unsafe HTTP methods (POST, PUT, PATCH, DELETE), an attacker can embed an <img> tag pointing to the trainer-login endpoint on a malicious page. When an authenticated trainer loads that page, the browser auto-issues the GET request with the session cookie attached, and the server executes django_login(), forcibly rebinding the trainer's session to an arbitrary user account.

Note: This is only exploitable by an attacker who can cause an authenticated user with the gym.gym_trainer permission to load a malicious page.

CVSS Base Scores

version 4.0
version 3.1