Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

请教两个问题 #94

Open
Open
@Mr-JingShi

Description

@Mr-JingShi

charline[512];

你好,大佬,最近我在学习PLT hook的相关知识,所以找到了xhook。
xhook写的太好了,让我学到了好多知识。

(1)Line49 line[512]够大吗?如果一行读不完,恰好在动态库名称或者路径的地方被截断了,strstr(line, pathname)一直等于NULL,那岂不永远找不到相应的内存页。
为什么不用getLine或者加上\n的判断,或者去掉对pathname的判断。
android对动态库的路径或者动态库的名称长度有严格限制吗,所以512够用?

(2)为什么要特殊处理跨内存页,实际应用中有遇到重定位函数表/GOT内容跨页的现象吗?
不是有严格的内存对齐要求(要么4要么8)?
这种PLT-GOT相关的条目不是程序刚运行时就分配地址了吗?
内存碎片对变量地址,可能导致变量跨页存储。
我实在不理解这个地方为什么要处理跨页。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp