bytecodealliance / bytecodealliance/cap-std
UNC and other DOS Device Paths unusable
- Ngôn ngữ chính
- Rust
- Star
- 821
- Fork
- 57
- Merge trung bình
- 1 giờ 16 phút
- Pull request đã merge (30 ngày)
- 4
Mô tả
The following logic:
https://github.com/bytecodealliance/cap-std/blob/72fdc307184a642eadef22864434109c01d01528/cap-primitives/src/windows/fs/get_path.rs#L18-L22
completely breaks DOS device UNC paths such as:
```
\\?\UNC\server\share\bar.exe
```
which would have to be translated to:
```
\\server\share\bar.exe
```
in addition to that, other DOS device paths such as:
```
\\?\Volume{b75e2c83-0000-0000-0000-602f00000000}\Test\Foo.txt
```
get completely ruined.
There also is a lack of `\\.\` handling. I'm also not sure why this gets stripped in the first place, `join` can handle these paths just fine.
Hướng dẫn đóng góp
Hướng nghiên cứu
Start in cap-primitives/src/windows/fs/get_path.rs at lines 18–22 and reproduce the handling of the example DOS device paths. Trace why the current logic strips or alters prefixes, then verify that UNC, volume, and \\.\ paths are preserved or translated as described in the issue.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- rust
- Lĩnh vực
- operating-systems
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100