Various parsing bugs
Chưa có ai nhận issue nà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
- 52/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Lĩnh vực
- backend
Hướng nghiên cứu
Start by reading the tar parser code that handles pax headers and numeric fields; the issue does not name specific files or tests. Use the linked N27, N28, F14, N20, F37, F29, and F30 cases to reproduce the reported behavior. Done means the parser handles each case according to the described POSIX behavior and rejects or correctly interprets invalid numeric values.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
I'm working on a test suite tar-minefield for tar file parsing (docs: stoppels.ch/tar), with the ultimate goal to ensure implementations converge on similar behavior, reducing parser differential vulnerabilities.
During this work, I found a few bugs in Haskell's tar.
Related to pax headers:
- A pax header with both
pathandlinkpathdropspath. Test cases: N27 (symlink) and N28 (hard link). In this test case, GNU tar, libarchive, Python, Go and others extract a file with a 120-character name, while Haskell'starproduces one with 100 chars. - The pax
sizeis ignored. POSIX: "This record shall override the size field in the following header block(s)". See F14. - For a repeated keyword, the first record wins, but according to POSIX: "When extended header records conflict, the last one given in the header shall take precedence". See N20.
Related to parsing of numeric fields:
8and9are accepted as octal digits, so a size of00000000090is read as 72, where GNU tar, libarchive, Python and most others refuse it. See F37.- A negative base-256 number is read as positive, so size of -512 becomes 512. See F29.
- A base-256 number that doesn't fit in 64 bits wraps around. See F30.
- Ngôn ngữ chính
- Haskell
- Star
- 42
- Fork
- 41
- 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
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 haskell/tar
-
Drop support for older GHCs.Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
-
Expose TarPath -> PosixStringĐang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 45/100
-
convert to `PosixPath`Có thể đã có người làm @hasufell đã nhận 1090 ngày trước. Đang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 25/100
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
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 72/100
haskell/bytestring#730 · 1 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
seal-harness/seal-harness#399 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
add previously overlooked rulesĐang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
fmidue/codeworld-tasks#124 ·
-
allow haskell-src-exts-1.24Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
reflex-frp/reflex#563 ·