Unable to use SOCKS proxy with Entra ID / OIDC authentication: missing 'socks' dependency for MongoDB connection
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 68/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Quiet
- Tech stack
- mongodb, node.js, typescript
- Domain
- authentication, database, networking
Research direction
Inspect the extension's package.json and bundle, then compare the upstream driver's src/cmap/connect.ts around the getSocks() path. Done means the socks dependency is declared and included in the shipped extension, and connections using proxyHost/proxyPort no longer fail with kModuleError.
Written by the indexing model from the issue text.
Description
Bug Description
The extension cannot connect to MongoDB databases over a SOCKS proxy because the required socks package is not included in the extension bundle. This breaks support for the proxyHost connection option, which is documented as supported in the upstream MongoDB Node.js driver (mongodb@~7.0.0).
Steps to Reproduce
- Attempt to connect to a MongoDB/CosmosDB database using Entra ID authentication (with
authMechanism=MONGODB-OIDC) and supplying aproxyHost=...andproxyPort=...option in the connection string (for example, behind a SOCKS5 jumpbox/proxy server). - The connection attempt times out after ~30 seconds and fails internally with
kModuleErrorfromgetSocks() - No user-facing error indicates that the
sockspackage is missing
Expected Behavior
- Extension should include the
sockspackage in its dependencies and bundle it correctly - When
proxyHost/proxyPortare specified, the extension should route the connection through a SOCKS5 proxy as supported by the upstream driver
Actual Behavior
- The extension fails to establish a connection over a SOCKS proxy
- Ultimately leads to timeout and internal error, sometimes with an unhelpful error message
- Debug logs reveal
kModuleErrorwhen trying to requiresocks
Environment
- Extension version: 0.7.2
- Node.js MongoDB driver bundled: ~7.0.0
- Host OS: [Please fill in]
Additional Context
- Upstream driver: https://github.com/mongodb/node-mongodb-native/blob/v7.0.0/src/cmap/connect.ts#L269
- The
sockspackage is required but not present in the VS Code extension'spackage.jsondependencies or the extension bundle - This blocks users who can only reach the database via a SOCKS5 proxy (e.g., jump host, cloud bastion) and need to use the OIDC/Entra ID authentication mechanism
Request:
- Please add
socksas a dependency and bundle it to restore support for connecting via a SOCKS proxy with Entra ID (OIDC) authentication.
Thank you!
- Dominant language
- TypeScript
- Stars
- 31
- Forks
- 22
- Avg merge
- 2d 20h
- Merged PRs (30d)
- 21
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from microsoft/vscode-documentdb
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
microsoft/vscode-documentdb#885 ·
-
bug-bash
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
microsoft/vscode-documentdb#875 · 1 reaction ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
microsoft/vscode-documentdb#831 · 1 comment ·
-
documentation needs-triage P3
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
microsoft/vscode-documentdb#643 ·
-
enhancement needs-triage
Difficulty 5/5 Over a week Newbie friendliness 30/100
microsoft/vscode-documentdb#931 ·
All issues in microsoft/vscode-documentdb
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
copse-dev/agent-pane#2953 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
bug clawsweeper:linked-pr-open clawsweeper:needs-live-repro clawsweeper:no-new-fix-pr impact:message-loss issue-rating: 🐚 platinum hermit P2 regression
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
calcite-components needs triage refactor
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Esri/calcite-design-system#15203 ·