Skip to main content

CVE-2025-47790: CWE-287: Improper Authentication in nextcloud security-advisories

Medium
VulnerabilityCVE-2025-47790cvecve-2025-47790cwe-287
Published: Fri May 16 2025 (05/16/2025, 14:02:57 UTC)
Source: CVE
Vendor/Project: nextcloud
Product: security-advisories

Description

Nextcloud Server is a self hosted personal cloud system. Nextcloud Server prior to 29.0.15, 30.0.9, and 31.0.3 and Nextcloud Enterprise Server prior to 26.0.13.15, 27.1.11.15, 28.0.14.6, 29.0.15, 30.0.9, and 31.0.3 have a bug with session handling. The bug caused skipping the second factor confirmation after a successful login with the username and password when the server was configured with `remember_login_cookie_lifetime` set to `0`, once the session expired on the page to select the second factor and the page is reloaded. Nextcloud Server 29.0.15, 30.0.9, and 31.0.3 and Nextcloud Enterprise Server is upgraded to 26.0.13.15, 27.1.11.15, 28.0.14.6, 29.0.15, 30.0.9 and 31.0.3 contain a patch. As a workaround, set the `remember_login_cookie_lifetime` in config.php to a value other than `0`, e.g. `900`. Beware that this is only a workaround for new sessions created after the configuration change. System administration can delete affected sessions.

AI-Powered Analysis

AILast updated: 07/11/2025, 23:47:50 UTC

Technical Analysis

CVE-2025-47790 is a medium severity vulnerability affecting multiple versions of Nextcloud Server and Nextcloud Enterprise Server prior to specific patched releases (29.0.15, 30.0.9, 31.0.3 for Server and 26.0.13.15 through 31.0.3 for Enterprise). The vulnerability stems from improper authentication (CWE-287) related to session handling when the server is configured with the parameter `remember_login_cookie_lifetime` set to 0. Under these conditions, after a user successfully logs in with username and password, the system is supposed to require a second factor authentication (2FA) confirmation. However, if the session expires on the 2FA selection page and the page is reloaded, the second factor confirmation step is skipped, allowing the user to bypass 2FA. This flaw effectively reduces the security of accounts protected by 2FA, potentially allowing attackers who have compromised primary credentials to gain full access without completing the second authentication step. The vulnerability requires low privileges (PR:L) and user interaction (UI:R) but can be exploited remotely (AV:N). The CVSS v3.1 base score is 6.4, reflecting high impact on confidentiality and integrity but no impact on availability. The issue is mitigated in patched versions of Nextcloud Server and Enterprise Server. A temporary workaround involves setting `remember_login_cookie_lifetime` to a non-zero value (e.g., 900 seconds) to prevent session expiration from triggering the bypass, though this only affects new sessions after the change. Administrators are also advised to delete affected sessions to mitigate risk. No known exploits are currently reported in the wild.

Potential Impact

For European organizations using Nextcloud as a self-hosted cloud solution, this vulnerability poses a significant risk to the confidentiality and integrity of sensitive data. Nextcloud is widely adopted in Europe, especially among public sector entities, educational institutions, and enterprises valuing data sovereignty. The bypass of 2FA undermines a critical security control, increasing the likelihood of unauthorized access if primary credentials are compromised through phishing, credential stuffing, or insider threats. This can lead to data breaches, unauthorized data modification, and potential compliance violations under GDPR due to inadequate access controls. The vulnerability does not impact availability, but the loss of confidentiality and integrity can have severe operational and reputational consequences. Organizations relying on Nextcloud for file sharing, collaboration, and document management must prioritize remediation to maintain trust and regulatory compliance.

Mitigation Recommendations

1. Immediate upgrade to the patched Nextcloud Server or Enterprise Server versions as listed (e.g., 29.0.15, 30.0.9, 31.0.3 or respective Enterprise versions) to fully remediate the vulnerability. 2. As a temporary measure before patching, set the `remember_login_cookie_lifetime` configuration parameter in config.php to a non-zero value such as 900 seconds to prevent session expiration from causing 2FA bypass. 3. Invalidate and delete all existing user sessions to ensure no active sessions are vulnerable to the bypass. 4. Review and strengthen monitoring and alerting for unusual login patterns or suspicious session activity, particularly failed or bypassed 2FA attempts. 5. Educate users about the importance of safeguarding primary credentials and recognizing phishing attempts, as credential compromise is a prerequisite for exploitation. 6. Consider implementing additional compensating controls such as IP-based restrictions or device trust policies to reduce risk during patch deployment. 7. Regularly audit Nextcloud configurations and session management settings to ensure compliance with security best practices.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
GitHub_M
Date Reserved
2025-05-09T19:49:35.622Z
Cisa Enriched
true
Cvss Version
3.1
State
PUBLISHED

Threat ID: 682cd0f91484d88663aebe3d

Added to database: 5/20/2025, 6:59:05 PM

Last enriched: 7/11/2025, 11:47:50 PM

Last updated: 8/12/2025, 12:40:21 PM

Views: 11

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

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

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats