Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Bug: conflicting auth sources silently prefer ?token= over Authorization header

Đang mở
#27 3 bình luận 0 reaction 0 người được giao Xem trên GitHub

@xyaz1313 đang làm issue này rồi.

Từ ngày 14/4/2026.

  • #36 của @xyaz1313 — đang mở
  • #37 của @xyaz1313 — đang mở
  • #38 của @xyaz1313 — đang mở

Đá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
15/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
python

Hướng nghiên cứu

Start by locating the middleware that reads the Authorization header and ?token= query parameter, then trace how it selects credentials. The issue does not name files or tests; first identify existing authentication tests and read the comments around the two open linked pull requests. Done means conflicting credentials follow a clearly chosen policy and the behavior is covered by tests.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

bug good first issue help wanted

Summary

If both an Authorization header and a ?token= query parameter are provided, the middleware silently replaces the header with the query token. In production that can hide client misconfiguration and make debugging auth problems harder.

Reproduction

  1. Send a request with Authorization: Bearer TOKEN_A.
  2. Also append ?token=TOKEN_B to the URL.
  3. Observe that the request is executed with TOKEN_B and the original header is discarded.

Expected

Either:

  • reject conflicting auth sources with 400, or
  • preserve one source deterministically and emit a strong warning.

Actual

The query token silently wins.

Why it matters

This is a realistic integration mistake with browser-hosted clients, local proxies, and copied config snippets.

Ngôn ngữ chính
Python
Star
22
Fork
4
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. 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.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của openapi/mcp-server

Tất cả issue của openapi/mcp-server

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.