From c45f74cc3e075d3b04dd920141e82a51dc20bd9b Mon Sep 17 00:00:00 2001 From: Munehisa Kamata Date: Tue, 4 Oct 2022 21:52:20 -0700 Subject: recovery: set bRequest to 1 when sending bootx command In macOS 13 beta 8 or newer release, bootx seems to fail if bRequest is 0 in the control transfer setup. Then, the device fails to enter restore mode. Seems like something has changed in iBEC since beta 8 and Apple Configurator 2 has set it to 1, so do the same thing. While this could be applied for all *OS variants, it's limited to macOS for now just to be safe. Signed-off-by: Munehisa Kamata --- src/recovery.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/recovery.c b/src/recovery.c index 1a9c970..24d0c3d 100644 --- a/src/recovery.c +++ b/src/recovery.c @@ -498,7 +498,7 @@ int recovery_send_kernelcache(struct idevicerestore_client_t* client, plist_t bu recovery_error = irecv_send_command(client->recovery->client, setba); } - recovery_error = irecv_send_command(client->recovery->client, "bootx"); + recovery_error = irecv_send_command_breq(client->recovery->client, "bootx", client->macos_variant ? 1 : 0); if (recovery_error != IRECV_E_SUCCESS) { error("ERROR: Unable to execute %s\n", component); return -1; -- cgit v1.1-32-gdbae