Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

DATABASE connectors keep a connection-string password in plaintext and return it to the browser

オープン
#1,245 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@Riteesh-2k6 がすでに取り組んでいます。

2026年10月25日 から。

  • #1253 @Riteesh-2k6 による — オープン

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
45/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
mongodb, mysql, postgresql, typescript

調査の方向性

Start from the connector serialization in toPublicConnector() and the SecretExtractor guard that skips DATABASE. Locate connector create/update handlers to move user:password from base URL into encrypted authConfig. Extend the secret-literal repair script and add tests for pg/mysql/mongodb/mssql/oracle URLs; done means passwords never appear in API responses and existing rows can be repaired.

索引モデルが issue の本文から書いたものです。

説明

Problem

A DATABASE connector can be created with its password inside the connection string, e.g. postgresql://app:[email protected]:5432/shop. In that case:

  • the password is stored in plaintext in connectors.base_url, while auth_config is encrypted and env_vars are sealed at rest;
  • toPublicConnector() masks env vars and headers but returns baseUrl unchanged, so the password goes back to the browser on every connector read (list, detail, update responses) and is visible to every member who can open the connector;
  • the secret guard that moves literal keys out of base URLs and headers (SecretExtractor, SECRET_GUARDED_TYPES) deliberately skips DATABASE, and so does the secret-literal report/repair script.

The engine already supports the safe form: DatabaseEngine splices authConfig.username / authConfig.password into pg, mysql and mongodb URLs, and the mssql and oracle drivers read them from authConfig directly. Nothing steers a user there when they paste a full connection string.

Proposal

  1. On create and update of a DATABASE connector, when the URL carries user:password@ and authConfig holds no password: move username and password into the encrypted authConfig and store the URL without the password. The connector connects exactly as before, since the engine puts them back at call time.
  2. In toPublicConnector(), as a second line of defence, return a DATABASE baseUrl with any password replaced by a mask, and keep the stored value when an edit sends the masked URL back (same rule as masked env vars).
  3. Existing rows: extend the secret-literal report/repair script to DATABASE base URLs, so operators can find and repair connectors created before this change.
  4. Tests for the three parts, including mssql/oracle/hana URLs and URLs that are not parseable (left as they are).

Deployment modes

Same behaviour on Cloud and self-hosted: both store connectors in the same table and serve them through the same API. The repair script is run by whoever operates the instance.

Open question

Whether to also refuse a password in the URL outright (400 with a hint to use the credential fields) instead of moving it silently. Moving it keeps existing API clients and imports working, so the proposal moves it.

主要言語
TypeScript
スター
856
フォーク
82
平均マージ
7時間 57分
マージ済み PR(30日)
290

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

HelpCode-ai/anythingmcp のほかの issue

HelpCode-ai/anythingmcp の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。