Shanghai National Police Database

WikipediaVerified

Breach Date

July 1, 2022

Records Affected

1,000,000,000

Verified

Yes

Source

wikipedia

Summary

The Shanghai National Police Database breach of July 2022 is widely considered the largest known data breach in Chinese history and one of the most significant government data leaks ever recorded. An anonymous hacker using the alias "ChinaDan" posted on Breach Forums offering to sell approximately 23 terabytes of data containing personal information on roughly 1 billion Chinese citizens. The asking price was 10 Bitcoin (approximately $200,000 at the time).

The exposed data included names, addresses, birthplaces, national ID numbers, phone numbers, photos, and detailed criminal case information — essentially a comprehensive dossier on a significant portion of China's population. Multiple international news outlets including the Wall Street Journal, New York Times, and CNN independently verified samples of the data by calling individuals listed in the dataset and confirming their identities.

The breach originated from an unsecured Elasticsearch database or dashboard hosted on Alibaba Cloud that was publicly accessible without authentication. Security researchers believe the database credentials were inadvertently exposed in a blog post on CSDN (China Software Developer Network). The Chinese government responded by censoring all related hashtags and discussions on Weibo and other domestic social media platforms, and no official acknowledgment, investigation results, or fines have been publicly announced.

Breach Details

Breach Date
July 1, 2022
Records Affected
1,000,000,000
Source
Wikipedia
Verified
Verified
Industry
Government
Type
Poor Security

Impact Analysis

Scale of Impact

  • Approximately 1 billion individuals affected — roughly 70% of China's total population
  • 23 terabytes of data exposed — one of the largest datasets ever leaked by volume
  • Criminal case records included, exposing sensitive law enforcement information alongside personal data

Data Types Exposed

  • Full names
  • Home addresses
  • Birthplaces
  • National ID numbers (equivalent to Social Security numbers)
  • Phone numbers
  • Photographs
  • Criminal case information and police records

Societal and Political Impact

CategoryImpact
Privacy exposure~1 billion citizens' government records leaked
Identity theft riskNational ID numbers + personal details enable fraud at massive scale
Government credibilitySevere damage to China's data governance reputation
Censorship responseAll related discussion censored on Chinese social media
Criminal intelligenceSensitive law enforcement case data exposed to adversaries

Downstream Effects

  • National ID numbers combined with names, photos, and addresses create comprehensive identity packages that can be used for identity fraud, social engineering, and targeted scams
  • Criminal case information could be weaponized for blackmail, extortion, or harassment of individuals with police records
  • The breach exposed the Chinese government's practice of aggregating massive citizen databases with minimal security controls
  • International observers raised concerns about the scope of personal data collected by Chinese law enforcement, including data on minor infractions and civil disputes
  • The incident sparked a broader discussion about cloud security practices for government data, particularly the risks of hosting sensitive government databases on commercial cloud platforms
  • Trust in Alibaba Cloud's security suffered reputational damage, with questions raised about how a government database of this sensitivity was left publicly accessible

Timeline

  • Date unknown (before July 2022): Shanghai National Police database hosted on Alibaba Cloud is deployed with an unsecured dashboard or Elasticsearch instance, publicly accessible without authentication
  • Date unknown: Database credentials reportedly appear in a blog post on CSDN (China Software Developer Network), potentially providing the access vector
  • Early July 2022: Hacker "ChinaDan" gains access to the database and begins exfiltrating approximately 23TB of data
  • July 3, 2022: ChinaDan posts on Breach Forums offering to sell the data for 10 BTC (~$200,000), claiming it contains personal information on approximately 1 billion Chinese citizens
  • July 4-6, 2022: International media outlets (Wall Street Journal, New York Times, CNN) begin investigating the claims and independently verify data samples by contacting individuals in the dataset
  • July 5, 2022: Security researchers identify the likely source as an unsecured Elasticsearch instance on Alibaba Cloud
  • July 5-6, 2022: Chinese authorities begin censoring all related hashtags on Weibo including "Shanghai data leak" and "data breach"; discussions are removed from WeChat and other platforms
  • July 6, 2022: Changpeng Zhao (CZ), CEO of Binance, tweets that Binance threat intelligence detected the sale and that the breach likely resulted from an exposed Elasticsearch deployment
  • July 2022 onward: The exposed database is taken offline, but no official Chinese government statement acknowledges the breach
  • As of 2026: No fines, sanctions, or official investigation results have been publicly announced by Chinese authorities

Lessons Learned

1. Government Databases Require the Highest Security Standards

A database containing records on 1 billion citizens was accessible on the public internet without authentication. This represents a catastrophic failure in basic security hygiene. Government agencies must treat citizen data as critical infrastructure, applying defense-in-depth strategies including network segmentation, encryption at rest and in transit, strict access controls, and continuous monitoring.

2. Cloud Misconfigurations Remain the Leading Cause of Mass Data Exposures

The breach appears to have resulted from a misconfigured Elasticsearch instance or dashboard on Alibaba Cloud that lacked authentication. This mirrors a pattern seen across hundreds of major breaches: cloud services deployed with default (open) configurations. Organizations must enforce configuration baselines, use cloud security posture management (CSPM) tools, and conduct regular audits of exposed services.

3. Credential Exposure in Developer Platforms Is a Critical Risk

Reports indicate that database credentials were exposed in a CSDN blog post. Developers routinely share code snippets, configuration examples, and troubleshooting guides containing embedded credentials. Organizations need automated secret scanning in code repositories and developer platforms, and must enforce credential rotation policies.

4. Transparency and Accountability Are Essential to Incident Response

The Chinese government's response — censoring discussion rather than acknowledging the breach and notifying affected individuals — stands in stark contrast to modern breach notification requirements in other jurisdictions (GDPR's 72-hour rule, SEC's 4-day rule). Without transparency, affected citizens cannot take protective measures, and the systemic issues that caused the breach are less likely to be addressed.

5. Data Minimization Limits Breach Impact

The fact that a single database contained names, addresses, national IDs, photos, phone numbers, and criminal records for 1 billion people illustrates the risks of data aggregation. Data minimization principles — collecting only what is necessary and storing different categories separately — would have significantly limited the impact of any single breach.

6. Massive Scale Does Not Equal Better Security

The sheer scale of the database (23TB, 1 billion records) may have contributed to complacency about its security. Large datasets require proportionally greater security investment. The breach demonstrates that no database is "too important to hack" — in fact, the most valuable targets often receive the most attention from attackers.

Technical Details

Infrastructure

The Shanghai National Police Database (often referred to as SHGA — Shanghai Gong'an, the Chinese term for Public Security Bureau) was hosted on Alibaba Cloud infrastructure. The database is believed to have been an Elasticsearch cluster or a Kibana dashboard that was deployed without proper authentication controls.

Attack Vector

  1. Exposed Service: An Elasticsearch instance or management dashboard was deployed on Alibaba Cloud with no authentication required for access
  2. Credential Leak: Database credentials were reportedly published in a blog post on CSDN (China Software Developer Network), a popular developer community platform in China
  3. Discovery: The hacker "ChinaDan" located the exposed service — whether through the CSDN credentials, internet-wide scanning (e.g., Shodan, Censys), or other reconnaissance methods is not confirmed
  4. Exfiltration: Approximately 23TB of data was extracted from the database, containing structured records on approximately 1 billion individuals
  5. Monetization: The data was listed for sale on Breach Forums for 10 BTC

Database Contents

Based on verified samples, the database contained multiple data categories:

  • Personal identifiers: Full names, national ID numbers (18-digit Chinese Resident Identity Card numbers), dates and places of birth
  • Contact information: Phone numbers, home addresses
  • Biometric data: Photographs (likely from ID card registrations)
  • Law enforcement records: Criminal case information including case descriptions, dates, and outcomes — covering cases from minor traffic violations to serious criminal offenses

Verification

Multiple independent verification efforts confirmed the data's authenticity:

  • Journalists from the Wall Street Journal, New York Times, and CNN called phone numbers in the dataset and confirmed individuals' identities
  • Security researchers cross-referenced records with publicly available information
  • The structured nature of the data and inclusion of internal police case numbers indicated it originated from an official law enforcement system

Attacker Profile

AttributeDetails
AliasChinaDan
PlatformBreach Forums
Asking price10 BTC (~$200,000 at July 2022 prices)
IdentityUnknown — no arrests or attributions announced
MotivationLikely financial (data sale)

Censorship Response

Chinese authorities implemented comprehensive censorship measures within days of the breach becoming public:

  • All related hashtags blocked on Weibo
  • Discussions removed from WeChat groups and Moments
  • Chinese-language media coverage suppressed
  • No official government statement issued acknowledging the breach

Frequently Asked Questions

How many people were affected by the Shanghai Police Database breach?

Approximately 1 billion Chinese citizens had their personal data exposed, representing roughly 70% of China's total population. The dataset contained 23 terabytes of structured data including names, national ID numbers, addresses, phone numbers, photos, and criminal case information.

Who was behind the breach?

The data was offered for sale by an anonymous hacker using the alias "ChinaDan" on Breach Forums. The hacker's true identity has never been publicly revealed, and no arrests have been announced. The breach itself was not a sophisticated hack but rather the exploitation of a publicly accessible, unsecured database.

How was the data verified as authentic?

Journalists from major international news outlets — including the Wall Street Journal, New York Times, and CNN — independently verified the data by calling phone numbers in the dataset. Individuals confirmed their names and other personal details matched the leaked records. Security researchers also cross-referenced records with other publicly available information.

What was China's official response to the breach?

The Chinese government has not officially acknowledged the breach. Instead, authorities censored all related discussions on domestic social media platforms including Weibo and WeChat, blocking relevant hashtags and removing posts. No fines, investigations, or accountability measures have been publicly announced.

How did the breach happen technically?

The data was stored in an Elasticsearch database or dashboard hosted on Alibaba Cloud that was publicly accessible without authentication. Reports indicate that database credentials may have been exposed in a blog post on CSDN, a Chinese developer community platform. The combination of an unsecured cloud deployment and potentially leaked credentials made the data accessible to anyone who knew where to look.

Was the data actually sold?

It is not publicly confirmed whether a transaction was completed. ChinaDan listed the data for 10 BTC (approximately $200,000 at the time) on Breach Forums. Regardless of whether the full dataset was sold, the posted samples were widely downloaded and circulated among security researchers and threat actors.

What should affected individuals do?

Given the nature of the data (government-issued national IDs, addresses, phone numbers), affected individuals face long-term identity theft risks. They should be vigilant about phishing attempts and social engineering scams that leverage their personal details. Unfortunately, unlike passwords, national ID numbers and birthplaces cannot be changed, making the exposure permanent.

Back to Breach Database
Breach data sourced from Wikipedia: List of data breaches, licensed under CC BY-SA 3.0.

Protect Your Organization From Data Breaches

Our security experts can help you identify vulnerabilities and strengthen your defenses.