Skip to content
KitploitKITPLOIT
工具漏洞利用博客
Log in
提交
工具漏洞利用博客
提交

黑客、渗透测试和网络安全工具,武装您的安全武器库!

Kitploit 是一个黑客、网络安全和渗透测试工具的目录。发现最新的项目更新,查找漏洞、分析系统、自动化测试并加强你的安全。

订阅源联系隐私© 2026 Kitploit

工具目录

分类

查看所有分类
Loading categories
CVE-2023-41992 — 针对CVE-2023-41992(macOS内核漏洞)的概念验证,演示了利用技术并提供了补丁分析。 | Kitploit
工具/GitHubGitHub/whw0x455/cve-2023-41992
iOS安全内存取证漏洞分析漏洞利用二进制利用
GitHubwhw0x455/cve-2023-41992

CVE-2023-41992

针对CVE-2023-41992(macOS内核漏洞)的概念验证,演示了利用技术并提供了补丁分析。

查看仓库
5512331年前Kitploit 审核通过
分享

CVE-2023-41992

这是 CVE-2023-41992 的概念验证。首先,这与 越狱 无关!并且它仍在开发中。

感谢到目前为止帮助过我的每个人。出于隐私考虑,我可能不在此列出你们。如果想让我列出,请私信我!

补丁

据我所知,补丁位于 ipc_right_destroy 中。也有人曾在 X(或 Twitter)上指出这一点。

diff --git a/osfmk/ipc/ipc_right.c b/osfmk/ipc/ipc_right.c
index a81ac21..32a9a3e 100644
--- a/osfmk/ipc/ipc_right.c
+++ b/osfmk/ipc/ipc_right.c
@@ -912,7 +912,6 @@ ipc_right_destroy(
        mach_port_type_t type;
 
        bits = entry->ie_bits;
-       entry->ie_bits &= ~IE_BITS_TYPE_MASK;
        type = IE_BITS_TYPE(bits);
 
        assert(is_active(space));

避免 ReportCrash 或 SIGKILL

使用 ipc_right_destroy 在 ipc 空间中留下一个无类型的 ipc 条目会触发异常。请查看下面的 [0] 和 [1]。

kern_return_t
ipc_right_destroy(
	ipc_space_t             space,
	mach_port_name_t        name,
	ipc_entry_t             entry,
	boolean_t               check_guard,
	uint64_t                guard)
{
...
		if (type == MACH_PORT_TYPE_SEND) {
			if (ip_is_pinned(port)) {
				assert(ip_active(port));
				is_write_unlock(space);
				mach_port_guard_exception_pinned(space,  // <---- [0]
                                        name, port, MPG_FLAGS_MOD_REFS_PINNED_DESTROY);
				return KERN_INVALID_CAPABILITY;
			}
			ipc_hash_delete(space, ip_to_object(port), name, entry);
		}
...
		if ((type & MACH_PORT_TYPE_RECEIVE) &&
		    (check_guard) && (port->ip_guarded) &&
		    (guard != port->ip_context)) {
			/* Guard Violation */
			uint64_t portguard = port->ip_context;
			ip_mq_unlock(port);
			is_write_unlock(space);
			/* Raise mach port guard exception */
			mach_port_guard_exception(name,  // <---- [1]
                                0, portguard, kGUARD_EXC_DESTROY);
			return KERN_INVALID_RIGHT;
		}

[0] 不会在第三方应用沙盒中杀死任务。我之前选择 mach_thread_self(),因为那是我能找到的唯一固定的发送权限。

但如果不避免 ReportCrash 或 SIGKILL,这个漏洞在 WebContent 沙盒中就没有用处。所以我进一步深入挖掘。

void
mach_port_guard_ast(thread_t t,
    mach_exception_data_type_t code, mach_exception_data_type_t subcode)
{
        ...
        	if (reason <= MAX_FATAL_kGUARD_EXC_CODE) {
		/*
		 * Fatal Mach port guards - always delivered synchronously.
		 * Check if anyone has registered for Synchronous EXC_GUARD, if yes then,
		 * deliver it synchronously and then kill the process, else kill the process
		 * and deliver the exception via EXC_CORPSE_NOTIFY.
		 */
		if (task_exception_notify(EXC_GUARD, code, subcode) == KERN_SUCCESS) {
			task_bsdtask_kill(task);
		} else {
			exit_with_guard_exception(get_bsdtask_info(task), code, subcode);
		}
        ...

内核中的 mach_port_guard_ast 处理 mach 端口保护异常。对于致命异常,它首先查找异常端口。如果异常通知返回 KERN_SUCCESS,则执行 SIGKILL。看起来很有希望,每个触发致命 mach 端口保护异常的任务都会被杀死。然而...

致命的 Mach 端口保护——始终同步传递。

我只需为触发漏洞的线程设置一个线程异常端口,并且不处理异常通知。内核会在这里等待回复,不会发送 SIGKILL。

一个 NULL 指针引用

  1. 创建一个接收端口和受害者端口,插入一些权限,进行一些端口保护。
  2. 通过端口描述符将受害者端口发送到接收端口
  3. 在另一个线程中使用我们自己的异常端口触发漏洞。
  4. 在接收端口上接收消息,内核崩溃。

在 ipc_right_copyout() 中出现恐慌,因为条目为空。

参考

  • blanket,复制了一些代码用于测试。
下载工具

最受欢迎

查看全部 →

发现我们社区最常用的工具。

  • 1

    OsintHunter

    letox4/osinthunter

    🎯 终极 OSINT 工具包:调查图谱、置信度评分、别名家族、地图、时间线和报告。49 个模块、400+ 个站点,无需 API 密钥。

    591
  • 2

    ghostlock-app

    yukonga/ghostlock-app

    GhostLock 一键执行应用(CVE-2026-43499)

    481
  • 3

    ARTEX

    baarai/artex

    基于LLM的多智能体自主渗透测试平台,具备规划器/执行器智能体、资产与探索图谱、MITM流量记录以及漏洞复测功能。

    389
  • 4

    redforge

    cybersecurity91/redforge

    浏览器端红队工具包,包含 102 个离线工具,用于侦察、载荷生成、凭据攻击、加密、编码和交战报告。

    332
  • 5

    CyberStrikeAI

    ed1s0nz/cyberstrikeai

    AI原生网络安全的行动系统——在这里,意图转化为受治理的执行,证据沉淀为运营记忆,每一次操作都让下一次更出色。

    255
  • 6

    antifox

    antifox-ai/antifox

    AI multi-agent autonomous penetration testing platform that runs recon, attack-surface discovery, exploitation validation and evidence-backed report delivery.

    247

探索所有工具

浏览我们的工具集合

查看所有工具 →