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

Hook某些函数导致进程崩溃的现象 #16

Open
gzliuqingyun opened this issue Oct 11, 2017 · 1 comment
Open

Hook某些函数导致进程崩溃的现象 #16

gzliuqingyun opened this issue Oct 11, 2017 · 1 comment

Comments

@gzliuqingyun
Copy link

Hi,你好
感谢提供如此好用的库,使用过程中发现一个问题,在Hook某些函数时,会导致目标进程的崩溃。
比如

  1. Hook用于socket通信的send函数
       #include <sys/types.h>
       #include <sys/socket.h>

       ssize_t send(int sockfd, const void *buf, size_t len, int flags);
  1. Hook用于读写的read函数
       #include <unistd.h>

       ssize_t read(int fd, void *buf, size_t count);

都发现了导致崩溃的问题。

不知道是否是这两个函数的汇编代码太短,导致hook时刷掉了原汇编代码以外的部分代码导致了崩溃的发生。

@cjycjw
Copy link

cjycjw commented Jul 8, 2019

我本地批量Hook了函数,但只要加上strcmp和strncmp的hook就崩溃,不知道什么原因!其他hook了8-9个函数都没有问题!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants