Atlassian Bitbucket Server and Data Center Command Injection Vulnerability (CVE-2022-43781) Alert

Atlassian Bitbucket Server and Data Center Command Injection Vulnerability (CVE-2022-43781) Alert

novembro 23, 2022 | Jie Ji

Overview

Recently, NSFOCUS CERT found that Atlassian officially fixed a command injection vulnerability in Bitbucket Server and Data Center. Due to flaws in Bitbucket Server and Data Center, attackers with user name control rights can implement command injection through environment variables, and eventually cause commands to be executed arbitrarily on the system. The CVSS score is 9.8. Affected users should take measures as soon as possible.

Atlassian Bitbucket Server and Data Center is a Git code hosting solution from Atlassian.

Reference link:

https://confluence.atlassian.com/bitbucketserver/bitbucket-server-and-data-center-security-advisory-2022-11-16-1180141667.html

Scope of Impact

Affected versions

  • 7.0 <= Bitbucket Server and Data Center <= 7.5
  • 7.6.0 <= Bitbucket Server and Data Center <= 7.6.18
  • 7.7 <= Bitbucket Server and Data Center <= 7.16
  • 7.17.0 <= Bitbucket Server and Data Center <=7.17.11
  • 7.18 <= Bitbucket Server and Data Center <= 7.20
  • 7.21.0 <= Bitbucket Server and Data Center <= 7.21.5

Note: If mesh.enabled=false is set in bitbucket.properties, the following versions are also affected by this vulnerability.

  • 8.0.0 <= Bitbucket Server and Data Center <= 8.0.4
  • 8.1.0 <= Bitbucket Server and Data Center <= 8.1.4
  • 8.2.0 <= Bitbucket Server and Data Center <= 8.2.3
  • 8.3.0 <= Bitbucket Server and Data Center <= 8.3.2
  • 8.4.0 <= Bitbucket Server and Data Center <= 8.4.1

Unaffected versions

  • Bitbucket Server and Data Center >= 7.6.19
  • Bitbucket Server and Data Center >=7.17.12
  • Bitbucket Server and Data Center >=7.21.6
  • Bitbucket Server and Data Center >=8.0.5
  • Bitbucket Server and Data Center >=8.1.5
  • Bitbucket Server and Data Center >=8.2.4
  • Bitbucket Server and Data Center >=8.3.3
  • Bitbucket Server and Data Center >=8.4.2
  • Bitbucket Server and Data Center >=8.5.0

Mitigation

Official Upgrade

At present, the official has fixed the vulnerability in the latest version. Please upgrade the version as soon as possible to protect the affected users. The official download link is as follows:

https://www.atlassian.com/software/bitbucket/download-archives

Temporary Mitigation

If the relevant user cannot perform the upgrade operation temporarily, the user can mitigate this vulnerability by disabling “Public Registration”: Administration > Authentication and clear the Allow public registration checkbox

Description: Disabling public registration changes the attack vector from unauthenticated to authenticated attacks, reducing the risk of exploitation, but users authenticated as ADMIN or SYS_ADMIN can still exploit the vulnerability. Therefore, this mitigation should be considered a temporary step and users are advised to upgrade to the fixed version as soon as possible.

Note: Bitbucket Server and Data Center instances running PostgreSQL are not affected by this vulnerability.

Statement

This advisory is only used to describe a potential risk. NSFOCUS does not provide any commitment or promise on this advisory. NSFOCUS and the author will not bear any liability for any direct and/or indirect consequences and losses caused by transmitting and/or using this advisory. NSFOCUS reserves all the rights to modify and interpret this advisory. Please include this statement paragraph when reproducing or transferring this advisory. Do not modify this advisory, add/delete any information to/from it, or use this advisory for commercial purposes without permission from NSFOCUS.

About NSFOCUS

NSFOCUS, Inc., a global network and cyber security leader, protects enterprises and carriers from advanced cyber attacks. The company’s Intelligent Hybrid Security strategy utilizes both cloud and on-premises security platforms, built on a foundation of real-time global threat intelligence, to provide multi-layered, unified and dynamic protection against advanced cyber attacks.

NSFOCUS works with Fortune Global 500 companies, including four of the world’s five largest financial institutions, organizations in insurance, retail, healthcare, critical infrastructure industries as well as government agencies. NSFOCUS has technology and channel partners in more than 60 countries, is a member of both the Microsoft Active Protections Program (MAPP), and the Cloud Security Alliance (CSA).

A wholly owned subsidiary of NSFOCUS Technologies Group Co., Ltd., the company has operations in the Americas, Europe, the Middle East and Asia Pacific.