Windows: Password Cache Causes Excessive Argon2 KDF Delays with High PIM Values

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

Maintainer thường phản hồi trong vòng 1 ngày

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
22/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
c
Lĩnh vực
performance, security

Hướng nghiên cứu

Start with ReadVolumeHeaderWCacheWithAbort() in src/Common/Cache.c, which loops over cached passwords and PIMs, and with its caller in src/Driver/Ntvol.c. Trace how ReadVolumeHeaderWithAbort() picks the PRF and reaches the Argon2 path when the PIM is above 31. Done means cached attempts no longer trigger the expensive derivation on Windows, with the cache behaviour checked against the Linux/macOS work in PR #1972. This touches crypto and kernel-driver code, so it is not a good first task without maintainer guidance.

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

Mô tả

bug
Source verification against VeraCrypt 1.26.30

The Windows password-cache path still contains the behavior described in this issue.

  1. In [src/Common/Cache.c](https://github.com/veracrypt/VeraCrypt/blob/VeraCrypt_1.26.30/src/Common/Cache.c#L58-L151), ReadVolumeHeaderWCacheWithAbort() stores cached passwords and PIM values, but does not retain the PRF/KDF that successfully opened each volume.

  2. When the supplied password is empty, the function iterates through cached passwords and calls ReadVolumeHeaderWithAbort() for each candidate using the same pkcs5_prf and the candidate's cached PIM.

  3. The Windows driver invokes this function through [src/Driver/Ntvol.c](https://github.com/veracrypt/VeraCrypt/blob/VeraCrypt_1.26.30/src/Driver/Ntvol.c#L622-L652).

  4. With KDF autodetection enabled and PIM values above 31, unsuccessful cached-password attempts can enter the expensive Argon2 derivation path. This can require approximately 1 GiB of memory per attempt, with computational cost increasing alongside PIM.

The Linux/macOS cache work in [PR #1972](https://github.com/veracrypt/VeraCrypt/pull/1972) does not cover the Windows driver. Its description explicitly identifies src/Common/Cache.c as unchanged. The same Windows-side limitation is also documented in [#1969](https://github.com/veracrypt/VeraCrypt/issues/1969).

Version reviewed: VeraCrypt 1.26.30
Tag: [VeraCrypt_1.26.30](https://github.com/veracrypt/VeraCrypt/tree/VeraCrypt_1.26.30)
Runtime qualification: The original Windows behavior was reported on 1.26.29. The persistence in 1.26.30 is confirmed by source inspection, not by a new runtime reproduction on that release.

Ngôn ngữ chính
C
Star
11.7k
Fork
1.4k
Merge trung bình
1 ngày 1 giờ
Pull request đã merge (30 ngày)
28

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

  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 veracrypt/VeraCrypt

Tất cả issue của veracrypt/VeraCrypt

Issue tương tự

Thêm issue về C

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.