arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2012.02554cs.CR
收藏

自动生成Linux应用程序的Seccomp过滤器

Automating Seccomp Filter Generation for Linux Applications

Claudio Canella, Mario Werner, Daniel Gruss, Michael Schwarz

摘要:

应用程序中的软件漏洞会破坏应用程序的安全性。通过阻止未使用的功能,可以减少潜在漏洞的影响。虽然seccomp提供了一个过滤系统调用的解决方案,但它需要为每个单独的应用程序手动实现过滤规则。最近的工作已经调查了用于检测和安装必要的过滤器规则的自动化方法。然而,正如我们所展示的,这些方法做出的假设是不必要的,或者需要过于耗时的分析。在本文中,我们提出了Chestnut,这是一种自动化的方法,用于为Linux用户空间应用程序生成严格的系统调用过滤器,具有较低的要求和限制。板栗包括两个阶段,第一阶段由两个静态组件组成,即,一个编译器和一个二进制分析器,它们在编译或分析二进制文件时提取使用过的系统调用。Chestnut基于编译器的方法比以前的方法快73倍,而不会对准确性产生不利影响。在二进制分析的水平上,我们证明了相关工作的位置无关的二进制文件的要求是不需要的,扩大了板栗是可用的应用程序集。在可选的第二个阶段,Chestnut提供了一个动态细化工具,允许进一步限制允许的系统调用集。我们表明,板栗平均块302系统调用(86.5%)通过编译器和288(82.5%)使用二进制级别的分析一组18个广泛使用的应用程序。我们发现Chestnut分别在50%和77.7%的测试应用程序中使用基于编译器和基于二进制的方法阻止了危险的exec系统调用。对于测试的应用程序,Chestnut阻止了175个通过系统调用针对内核的CVE中超过62%的漏洞。最后,我们对一个沙箱Nginx服务器进行了为期6个月的长期研究。

英文摘要:

Software vulnerabilities in applications undermine the security of applications. By blocking unused functionality, the impact of potential exploits can be reduced. While seccomp provides a solution for filtering syscalls, it requires manual implementation of filter rules for each individual application. Recent work has investigated automated approaches for detecting and installing the necessary filter rules. However, as we show, these approaches make assumptions that are not necessary or require overly time-consuming analysis. In this paper, we propose Chestnut, an automated approach for generating strict syscall filters for Linux userspace applications with lower requirements and limitations. Chestnut comprises two phases, with the first phase consisting of two static components, i.e., a compiler and a binary analyzer, that extract the used syscalls during compilation or in an analysis of the binary. The compiler-based approach of Chestnut is up to factor 73 faster than previous approaches without affecting the accuracy adversely. On the binary analysis level, we demonstrate that the requirement of position-independent binaries of related work is not needed, enlarging the set of applications for which Chestnut is usable. In an optional second phase, Chestnut provides a dynamic refinement tool that allows restricting the set of allowed syscalls further. We demonstrate that Chestnut on average blocks 302 syscalls (86.5%) via the compiler and 288 (82.5%) using the binary-level analysis on a set of 18 widely used applications. We found that Chestnut blocks the dangerous exec syscall in 50% and 77.7% of the tested applications using the compiler- and binary-based approach, respectively. For the tested applications, Chestnut prevents exploitation of more than 62% of the 175 CVEs that target the kernel via syscalls. Finally, we perform a 6 month long-term study of a sandboxed Nginx server.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑