Skip to content
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

修改其他连接错误 #801

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -184,4 +184,4 @@ int main(int argc, char * argv[]){

## 参考文献

- [https://github.com/shellphish/how2heap/blob/master/glibc_2.25/house_of_lore.c](https://github.com/shellphish/how2heap/blob/master/glibc_2.25/house_of_lore.c)
- [https://github.com/shellphish/how2heap/blob/master/glibc_2.27/house_of_lore.c](https://github.com/shellphish/how2heap/blob/master/glibc_2.27/house_of_lore.c)
Original file line number Diff line number Diff line change
Expand Up @@ -734,7 +734,7 @@ tcache_put (mchunkptr chunk, size_t tc_idx)

因为没有任何检查,所以我们可以对同一个 chunk 多次 free,造成 cycliced list。

以 how2heap 的 [tcache_dup](https://github.com/shellphish/how2heap/blob/master/glibc_2.26/tcache_dup.c) 为例分析,源码如下:
以 how2heap 的 [tcache_dup](https://github.com/shellphish/how2heap/blob/master/glibc_2.27/tcache_dup.c) 为例分析,源码如下:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

该链接404

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

只是提个建议,毕竟文档多起来如果引用其他项目不使用commit id,不是很好管理

PS:堆方面我还是初学者就不班门弄斧了

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bash-c @Ascotbe 使用 commit id 作为超链接确实是不错的解决方案。针对目前的情况,具体要改到哪一个 commit id 估计得手工找一下。不过最近比较忙,暂时没有时间来处理这个 o(╥﹏╥)o 。@Ascotbe 欢迎在学习的过程中给出 PR 鸭

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bash-c 好的,我有空就提交PR

```C
glibc_2.26 [master●] bat ./tcache_dup.c
───────┬─────────────────────────────────────────────────────────────────────────────────
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ main_arena_offset = ELF("libc.so.6").symbols["__malloc_hook"] + 0x10



这里我以 shellphish 的 how2heap 仓库中的 [unsorted_bin_attack.c](https://github.com/shellphish/how2heap/blob/master/unsorted_bin_attack.c) 为例进行介绍,这里我做一些简单的修改,如下
这里我以 shellphish 的 how2heap 仓库中的 [unsorted_bin_attack.c](https://github.com/shellphish/how2heap/blob/master/glibc_2.27/unsorted_bin_attack.c) 为例进行介绍,这里我做一些简单的修改,如下

```c
#include <stdio.h>
Expand Down