Navigation guard misses redirect hops to private addresses
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 68/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- typescript
- Lĩnh vực
- security
Hướng nghiên cứu
Read the page.route('**/*') handler and the existing assertPublicUrl and isPublicHost checks; then find the tests for request routing. Add a test where a public URL redirects to a private address, and verify that the redirect is blocked before the browser follows it.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
The SSRF guard from #18 checks the initial URL (assertPublicUrl) and every request seen by page.route('**/*'). Playwright only calls the route handler for the first URL in a redirect chain, so a public URL that redirects to a private or link-local address is followed without being checked.
Reproduction (appwrite/browser 0.3.5, Appwrite Cloud staging and production, 2026-10-04/05):
/v1/avatars/screenshots?url=https://httpbin.org/redirect-to?url=http%3A%2F%2F169.254.169.254%2Flatest%2Fmeta-data%2Fpasses the API's URL validator (the initial host is public), and the browser follows the redirect to169.254.169.254. The request timed out after 30s with nothing returned, apparently because the address isn't reachable from the pod. The guard did not stop it.- A direct private URL, or a hostname that resolves privately (
10.0.0.1.nip.io), is refused, but by the API's validator before the browser is involved.
Expected: every hop is checked with isPublicHost, and a redirect to a non-public host aborts the navigation (blockedbyclient).
Possible fix: in the route handler, fetch with redirects disabled (route.fetch({ maxRedirects: 0 })). On a 3xx, resolve Location against the request URL, check it with isPublicHost, and either abort or route.fulfill the redirect response so the browser re-requests the next hop, which passes through the handler again. Add a test with a public redirect to a private address.
Context: appwrite-labs/cloud#6236 (cloud runs 0.3.5 since 2026-10-05).
- Ngôn ngữ chính
- TypeScript
- Star
- 8
- Fork
- 2
- Merge trung bình
- 21 phút
- Pull request đã merge (30 ngày)
- 2
Chuẩn bị môi trường
- Có Dockerfile hoặc tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
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 appwrite/docker-browser
-
Curl not working anymore.Đang mởdocumentation
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 52/100
appwrite/docker-browser#15 ·
Tất cả issue của appwrite/docker-browser
Issue tương tự
-
Table: Space fires onActivate in single-selection mode — the reference doc and the JSDoc disagreeĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
sidorares/react-x11-components#764 ·
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 76/100
backnotprop/plannotator#1840 ·
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 78/100
JoviDeCroock/pracht#432 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Add: CNN en Espanol SDĐang mởapproved check:passed streams:add
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 75/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Hardware attribute name "app Connection Support" has inconsistent casingCó thể đã có người làm Có pull request liên kết đang mở hoặc đã được merge. Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 88/100
walletbeat/walletbeat#1628 ·
Maintainer thường phản hồi trong vòng 1 ngày