-
Notifications
You must be signed in to change notification settings - Fork 446
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Heap overflow during hts_md5_update #1700
Comments
jkbonfield
added a commit
to jkbonfield/htslib
that referenced
this issue
Nov 16, 2023
This was checked for with aligned data, but unmapped "placed" reads could start beyind the reference end and cr->aend was dutifully set where it claimed to start. This could cause buffer read-overruns when computing the reference md5. Fixes samtools#1698, fixes samtools#1700
jkbonfield
added a commit
to jkbonfield/htslib
that referenced
this issue
Nov 16, 2023
This was checked for with aligned data, but unmapped "placed" reads could start beyind the reference end and cr->aend was dutifully set where it claimed to start. This could cause buffer read-overruns when computing the reference md5. Fixes samtools#1698, fixes samtools#1700
jkbonfield
added a commit
to jkbonfield/htslib
that referenced
this issue
Nov 16, 2023
This was checked for with aligned data, but unmapped "placed" reads could start beyind the reference end and cr->aend was dutifully set where it claimed to start. This could cause buffer read-overruns when computing the reference md5. Fixes samtools#1698, fixes samtools#1700
jkbonfield
added a commit
to jkbonfield/htslib
that referenced
this issue
Nov 17, 2023
This was checked for with aligned data, but unmapped "placed" reads could start beyind the reference end and cr->aend was dutifully set where it claimed to start. This could cause buffer read-overruns when computing the reference md5. Fixes samtools#1698, fixes samtools#1700
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Summary
Heap-buffer overflow in
hts_md5_update
during parsing of a crafted SAM/FASTA file pair.Environment
Built using LLVM 14 with ASAN on Ubuntu 22.04
How to reproduce
Build with ASAN on latest commit like so:
Within the samtools folder, get poc file and reproduce with:
Which on my setup outputs:
Note that this may be related to #1693 . However, both the allocation site and the function in which the faulty access occur are different.
The text was updated successfully, but these errors were encountered: