Visual Studio Extensions Revisited - #2884
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://mdsec.co.uk/2026/05/visual-studio-extensions-revisited Content Categories: Based on the analysis, this content was categorized under "Generic Hacking → Software Supply-Chain and IDE/Developer Extension Abuse (new subsection)". 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, severity, and security model. MDSec’s post, dated 28 May 2026, revisits Visual Studio extensions as an initial-access and software-supply-chain mechanism. It follows earlier research into VS Code extension abuse and references GitHub’s report of unauthorized access involving a compromised VS Code extension. The Visual Studio technique is not a named CVE or memory-corruption vuln...
🔧 Technical Details
Editor-event execution: A malicious
VisualStudio.Extensibilityextension can implementITextViewOpenClosedListenerand place code inTextViewOpenedAsync. By applyingDocumentFilter.FromDocumentType("json")or another common document filter, the extension executes automatically when the user opens a matching file. A legitimate feature such as JSON formatting can conceal the malicious action. The same approach can be adapted to text-change listeners or other editor events.In-memory remote assembly staging: The extension can call an HTTP endpoint, read a Base64 response, decode it with
Convert.FromBase64String, create a collectibleAssemblyLoadContextusing a generated name andtruefor collectibility, load the bytes withLoadFromStream, locateEntryPointthrough reflection, invoke it with an optionalstring[]🤖 Agent ActionsPlan:Repository review points to the existing editor-plugin abuse page as the closest fit. I’m broadening that page rather than creating a redundant generic-hacking page, and I’ll keep the Visual Studio material explicitly separated from privilege escalation.
Implemented the HackTricks update.
Changes
ITextViewOpenClosedListenerAssemblyLoadContext.LoadFromStreamstagingilspycmdAllUsersinstallation is not privilege escalationsrc/SUMMARY.mdnavigation.Validation
git diff --checkpassed.<details>blocks, citations, references, banner, and SUMMARY path validated.mdbookwas unavailable, so a full build could not be run.This PR was automatically created by the HackTricks Feed Bot. Please review the changes carefully before merging.