microsoft / microsoft/language-server-protocol

Feature Request: Support for marking custom extension parameters as sensitive (trace-safe)

Open
#2,249 4 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

feature-request help wanted
Dominant language
TypeScript
Stars
13k
Forks
1k
Avg merge
6d 1h
Merged PRs (30d)
10

Description

Context

We are building a language server that authenticates against external systems. Credentials (bearer tokens, username/password pairs) need to be provided by the user via the language client (e.g. VS Code) and transmitted to the language server via a custom LSP extension.

Problem

The vscode-languageclient library (and likely other client implementations) supports enabling a low-level JSON-RPC traffic trace, which can log the full payload of every request, response, and notification to an output channel (in VS Code, via "<id>.trace.server": "verbose" setting). This means any credentials passed as parameters in a custom extension request would appear in plain text in that output, which is a serious security issue.

We searched the specification and found no way to mark a parameter or an entire request/notification as sensitive, to signal that its content must be redacted or suppressed in such trace outputs.

Question / Request

Is there an existing convention or workaround for this that we may have missed?

If not, is this something worth addressing in the spec? For example via:

  • a way to mark a parameter / notification / request as sensitive
  • a client capability that the server can inspect to determine whether the client guarantees redaction of sensitive parameters in traces. This would allow the server to gracefully disable functionality that requires sensitive data when talking to a client that cannot provide that guarantee

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the LSP specification and the vscode-languageclient trace behavior described in the issue. Compare existing conventions for requests, notifications, parameters, and client capabilities. Done means the project has reached a documented decision on how sensitive data should be represented or handled in traces.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript, vscode
Domain
api, security
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.