NativePocMallocDebugAsserter

public class NativePocMallocDebugAsserter
extends Object implements NativePocAsserter

java.lang.Object
   ↳ com.android.sts.common.NativePocMallocDebugAsserter


摘要

公用方法

static NativePocAsserter assertNoMallocDebugErrorOnPoc(String options)

傳回 NativePocAsserter,將 libc malloc 偵錯功能附加至 PoC,並在 PoC 執行期間檢查任何 malloc 偵錯錯誤。

static NativePocAsserter assertNoMallocDebugErrorOnService(String options, String service)

會傳回 NativePocAsserter,該工具會在執行 PoC 之前將 libc malloc 偵錯功能附加至服務,並在 PoC 執行期間檢查該服務上的任何 malloc 偵錯錯誤。

AutoCloseable withAutoCloseable(NativePoc nativePoc, ITestDevice device)

在 PoC 執行前呼叫,會傳回在 PoC 完成後關閉的 AutoCloseable

公用方法

assertNoMallocDebugErrorOnPoc

public static NativePocAsserter assertNoMallocDebugErrorOnPoc (String options)

傳回 NativePocAsserter,將 libc malloc 偵錯功能附加至 PoC,並在 PoC 執行期間檢查任何 malloc 偵錯錯誤。

參數
options String

傳回
NativePocAsserter

assertNoMallocDebugErrorOnService

public static NativePocAsserter assertNoMallocDebugErrorOnService (String options, 
                String service)

會傳回 NativePocAsserter,該工具會在執行 PoC 之前將 libc malloc 偵錯功能附加至服務,並在 PoC 執行期間檢查該服務上的任何 malloc 偵錯錯誤。

參數
options String

service String

傳回
NativePocAsserter

withAutoCloseable

public AutoCloseable withAutoCloseable (NativePoc nativePoc, 
                ITestDevice device)

在 PoC 執行前呼叫,會傳回在 PoC 完成後關閉的 AutoCloseable

參數
nativePoc NativePoc

device ITestDevice

傳回
AutoCloseable

擲回
DeviceNotAvailableException
TimeoutException
ProcessUtil.KillException