| 제목 | go-kratos kratos 2.9.2 Unintended Route Exposure via DefaultServeMux Fallback |
|---|
| 설명 | The Kratos HTTP server (`transport/http/server.go`) sets `http.DefaultServeMux` as the fallback handler for both unmatched routes (`NotFoundHandler`) and disallowed methods (`MethodNotAllowedHandler`).
In Go, `http.DefaultServeMux` is a global, shared ServeMux instance. Numerous standard library and third-party packages automatically register handlers on it during `init()`. The most notable example is `net/http/pprof`, which registers debug profiling endpoints. Kratos itself ships a pprof wrapper package (`transport/http/pprof`) that imports `net/http/pprof`. |
|---|
| 원천 | ⚠️ https://github.com/go-kratos/kratos/issues/3810 |
|---|
| 사용자 | Yu_Bao (UID 89348) |
|---|
| 제출 | 2026. 04. 04. PM 03:51 (24 날 ago) |
|---|
| 모더레이션 | 2026. 04. 24. PM 09:43 (20 days later) |
|---|
| 상태 | 수락 |
|---|
| VulDB 항목 | 359545 [go-kratos 까지 2.9.2 http.DefaultServeMux Fallback transport/http/server.go NewServer 권한 상승] |
|---|
| 포인트들 | 20 |
|---|