TiDB 8.5.2 Security Assessment Unauthenticated Internal APIs... - #2888
Open
carlospolop wants to merge 1 commit into
Open
carlospolop wants to merge 1 commit into
carlospolop wants to merge 1 commit into
Conversation
Collaborator
Author
🔗 Additional ContextOriginal Blog Post: https://nccgroup.com/research/public-report-tidb-security-assessment Content Categories: Based on the analysis, this content was categorized under "Network Services Pentesting → new 'Pentesting TiDB' page, with cross-references to the Web/Golang material for exposed pprof and HTTP management endpoints. The page should focus on listener enumeration, Prometheus and TiDB status/configuration API exposure, unauthenticated administrative routes, and plaintext TiDB component communication, while omitting generic dependency findings unless they are tied to an exploitable call path.". Repository Maintenance:
Review Notes:
Bot Version: HackTricks News Bot v1.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 Automated Content Update
This PR was automatically generated by the HackTricks News Bot based on a technical blog post.
📝 Source Information
🎯 Content Summary
Scope and methodology. In the summer and fall of 2025, PingCAP engaged NCC Group to perform a code-assisted security assessment of the cloud-native distributed SQL database TiDB 8.5.2. The assessment ran from June 25, 2025 through September 4, 2025 and combined white-box source-code review, static analysis, targeted manual review, and dynamic testing of a dedicated deployment. One consultant performed 45 person-days of testing against Go and Rust components. The assessment identified e...
🔧 Technical Details
Discover and abuse network-exposed management interfaces. When a distributed database binds monitoring, status, configuration, or administrative HTTP services to
0.0.0.0or*without authentication and TLS, an attacker who reaches the internal network can first enumerate listeners withnetstat -tlnp, identify service ports and owning processes, and then issue unauthenticated HTTP requests. Prometheus on port9090, TiDB status interfaces on port10080, and related monitoring services can expose information or allow service-state operations without database credentials. The technique depends on network access and is primarily a post-compromise or internal-network attack.Use exposed Go
pprofendpoints for runtime reconnaissance. An unauthenticated/debug/pprof/interface can be queried to obtain profiling data, goroutine stacks, function information, object memory addres...🤖 Agent Actions
Plan:
Repository review shows no TiDB page. The closest pages cover single database protocols, while this assessment concerns a multi-listener database cluster and its management plane, so a dedicated network-services page is the least duplicative fit. I’ll use the report as the primary source and official PingCAP docs only to verify ports, routes, and TLS behavior.
Research confirms the useful delta: TiDB’s SQL listener is only one part of the attack surface. The TiDB status listener exposes self-documenting HTTP routes and pprof; PD’s client/API port includes both read-only topology endpoints and state-changing routes; TLS/mTLS changes the security boundary across these listeners. I’ll omit dependency inventories and unproven RCE claims.
Implementation is complete. I added the TiKV status plane as a distinct section because the audited Rust server exposes its own read-only and mutating routes on
20180; this avoids incorrectly treating every/debug/pprof/*path as Go-specific. I’m doing the final consistency and diff checks now.Implemented the TiDB documentation update.
Changes
src/network-services-pentesting/4000-10080-pentesting-tidb.mdsrc/SUMMARY.md.pentesting-web/golang.md.Validation
git diff --checkpassed.mdbookandmarkdownlintwere not installed, so those checks could not run.This PR was automatically created by the HackTricks Feed Bot. Please review the changes carefully before merging.