Oops, I Weaponized the Database Abusing AI Features in SQL S...#2359
Open
carlospolop wants to merge 1 commit into
Open
Oops, I Weaponized the Database Abusing AI Features in SQL S...#2359carlospolop wants to merge 1 commit into
carlospolop wants to merge 1 commit into
Conversation
Collaborator
Author
🔗 Additional ContextOriginal Blog Post: https://specterops.io/blog/2026/06/10/oops-i-weaponized-the-database-abusing-ai-features-in-mssql-2025 Content Categories: Based on the analysis, this content was categorized under "Network Services Pentesting > 1433 - Pentesting MSSQL - Microsoft SQL Server > SQL Server 2025 AI feature abuse / sp_invoke_external_rest_endpoint / CREATE EXTERNAL MODEL". 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
Blog focus: SpecterOps demonstrates how Microsoft SQL Server 2025 AI-related features can be abused as database-native exfiltration, NTLM coercion, and command-and-control transport primitives. This is not presented as a CVE; the techniques abuse intended SQL Server 2025 functionality, especially
sp_invoke_external_rest_endpoint,CREATE EXTERNAL MODEL, andAI_GENERATE_EMBEDDINGS.PoC repository: all proof-of-concep...
🔧 Technical Details
Database-native HTTPS exfiltration: If an attacker has sufficient SQL Server privileges,
sp_configure 'external rest endpoint enabled', 1enablessp_invoke_external_rest_endpoint, allowing SQL Server to send arbitrary HTTPS requests. Sensitive rows can be serialized withFOR JSON AUTOand posted to an attacker server in payloads up to 100 MB. This moves exfiltration into the database engine and avoids noisier PowerShell or implant-based transfer paths.File exfiltration through SQL Server: When SQL Server can read local files,
OPENROWSET(BULK N'path', SINGLE_CLOB)can load file contents into a SQL variable. The attacker can then POST the file contents withsp_invoke_external_rest_endpoint. This makes MSSQL the network origin for file theft and can bypass monitoring focused on traditional endpoint processes.Persistent table exfiltration with triggers: An at...
🤖 Agent Actions
Done.
Updated:
src/network-services-pentesting/pentesting-mssql-microsoft-sql-server/README.mdAdded concise coverage for:
sp_invoke_external_rest_endpointabuseFOR JSON AUTO+OPENROWSETCREATE EXTERNAL MODEL/AI_GENERATE_EMBEDDINGSValidation:
git diff --checkpassedmdbook buildcouldn’t run becausemdbookisn’t installed in this environmentThis PR was automatically created by the HackTricks Feed Bot. Please review the changes carefully before merging.