DATABASE connectors keep a connection-string password in plaintext and return it to the browser
Maintainer thường phản hồi trong vòng 1 ngày
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 45/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- mongodb, mysql, postgresql, typescript
Hướng nghiên cứu
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.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
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, whileauth_configis encrypted andenv_varsare sealed at rest; toPublicConnector()masks env vars and headers but returnsbaseUrlunchanged, 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
- On create and update of a DATABASE connector, when the URL carries
user:password@andauthConfigholds no password: move username and password into the encryptedauthConfigand store the URL without the password. The connector connects exactly as before, since the engine puts them back at call time. - In
toPublicConnector(), as a second line of defence, return a DATABASEbaseUrlwith 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). - Existing rows: extend the secret-literal report/repair script to DATABASE base URLs, so operators can find and repair connectors created before this change.
- 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.
- Ngôn ngữ chính
- TypeScript
- Star
- 856
- Fork
- 82
- Merge trung bình
- 8 giờ 14 phút
- Pull request đã merge (30 ngày)
- 258
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của HelpCode-ai/anythingmcp
-
Write example prompts and a FAQ for the Zucchetti and TeamSystem satellitesCó thể đã có người làm Có pull request liên kết đang mở hoặc đã được merge. Đang mởgood first issue hacktoberfest
Độ khó 2/5 Nửa ngày Mức phù hợp với người mới 70/100
HelpCode-ai/anythingmcp#996 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
enhancement good first issue hacktoberfest help wanted
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
HelpCode-ai/anythingmcp#982 · 10 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
good first issue hacktoberfest
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 85/100
HelpCode-ai/anythingmcp#1244 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Write example prompts and a FAQ for the German ERP satellites (JTL-Wawi, Haufe X360, Sage 100)Đang mởgood first issue hacktoberfest
Độ khó 3/5 Nửa ngày Mức phù hợp với người mới 82/100
HelpCode-ai/anythingmcp#1243 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
enhancement hacktoberfest help wanted
Độ khó 3/5 Nửa ngày Mức phù hợp với người mới 85/100
HelpCode-ai/anythingmcp#1240 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của HelpCode-ai/anythingmcp
Issue tương tự
-
Native Web
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 80/100
digitalfabrik/integreat-app#4517 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
TLS guide repeats certs/ in the certificate directoryCó thể đã có người làm @maheshrijal đã nhận hôm nay. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 92/100
prometheus/docs#3156 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 83/100
medusajs/dtc-starter#90 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
usability
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
inmanta/web-console#7632 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
zaidmukaddam/scira#261 ·