mirror of
https://github.com/palera1n/palera1n.git
synced 2026-10-23 18:49:48 +02:00
Add -B, remove -C
This commit is contained in:
1 parent
9a93f9e340
commit
d07875981a
3 files changed
+15
-19
No files matched your search
+6
-7
@@ -11,7 +11,7 @@
|
||||
.Nd iOS 15+ arm64 iOS/iPadOS jailbreaking tool
|
||||
.Sh SYNOPSIS
|
||||
.Nm
|
||||
.Op Fl cCdDEfhlnLOpRsvV
|
||||
.Op Fl BcdDEfhlnLOpRsvV
|
||||
.Op Fl e Ar Boot arguments
|
||||
.Op Fl k Ar Pongo image
|
||||
.Op Fl o Ar overlay file
|
||||
@@ -99,16 +99,15 @@ files. As a result, using the loader app to install the jailbreak environment
|
||||
is not supported when this option is used together with
|
||||
.Fl f , -fakefs
|
||||
\[char46]
|
||||
.It Fl B , -setup-fakefs-partial
|
||||
Like
|
||||
.Fl c , -setup-fakefs
|
||||
but the size of the created fakefs is smaller at the expense of having unwritable
|
||||
parts in rarely-written paths. (good for 16 GB devices)
|
||||
.It Fl c , -setup-fakefs
|
||||
When used with
|
||||
.Fl f , -fakefs ,
|
||||
Create the new APFS volume required for rootful. Will fail if one already exists.
|
||||
.It Fl C , -setup-fakefs-forced
|
||||
When used with
|
||||
.Fl f , -fakefs ,
|
||||
behaves like
|
||||
.Fl c , -setup-fakefs ,
|
||||
but existing fakefs, if exists, will be overwritten instead.
|
||||
.It Fl d , -demote
|
||||
Set the effective production fuse to 0, so as to enable hardware debugging features.
|
||||
.It Fl D , -dfuhelper-only
|
||||
|
||||
@@ -58,6 +58,7 @@
|
||||
#define palerain_option_jbinit_log_to_file (1 << 1) /* log to /cores/jbinit.log */
|
||||
#define palerain_option_setup_rootful (1 << 2) /* create fakefs */
|
||||
#define palerain_option_setup_rootful_forced (1 << 3) /* create fakefs over an existing one */
|
||||
#define palerain_option_setup_partial_root (1 << 4) /* fakefs creating should be partial */
|
||||
|
||||
#ifdef DEV_BUILD
|
||||
#define palerain_option_test1 (1 << 29)
|
||||
|
||||
+8
-12
@@ -16,8 +16,8 @@ checkrain_option_t host_flags = 0;
|
||||
checkrain_option_p host_flags_p = &host_flags;
|
||||
|
||||
static struct option longopts[] = {
|
||||
{"setup-partial-fakefs", no_argument, NULL, 'B'},
|
||||
{"setup-fakefs", no_argument, NULL, 'c'},
|
||||
{"setup-fakefs-forced", no_argument, NULL, 'C'},
|
||||
{"dfuhelper", no_argument, NULL, 'D'},
|
||||
{"help", no_argument, NULL, 'h'},
|
||||
{"pongo-shell", no_argument, NULL, 'p'},
|
||||
@@ -66,8 +66,8 @@ static int usage(int e, char* prog_name)
|
||||
"\t-1, --test1\t\t\t\tSet palerain_option_test1\n"
|
||||
"\t-2, --test2\t\t\t\tSet palerain_option_test2\n"
|
||||
#endif
|
||||
"\t-B, --setup-partial-fakefs\t\tSetup partial fakefs\n"
|
||||
"\t-c, --setup-fakefs\t\t\tSetup fakefs\n"
|
||||
"\t-C, --setup-fakefs-forced\t\tSetup fakefs and overwrite any existing ones\n"
|
||||
"\t-d, --demote\t\t\t\tDemote\n"
|
||||
"\t-D, --dfuhelper-only\t\t\tExit after entering DFU\n"
|
||||
"\t-e, --boot-args <boot arguments>\tXNU boot arguments\n"
|
||||
@@ -106,20 +106,20 @@ int optparse(int argc, char* argv[]) {
|
||||
int index;
|
||||
while ((opt = getopt_long(argc, argv,
|
||||
#ifdef DEV_BUILD
|
||||
"12cCDEhpvVldsOLftRnPe:o:r:K:k:i:",
|
||||
"12BcDEhpvVldsOLftRnPe:o:r:K:k:i:",
|
||||
#else
|
||||
"cCDEhpvVldsOLfRnPe:o:r:K:k:i:",
|
||||
"BcDEhpvVldsOLfRnPe:o:r:K:k:i:",
|
||||
#endif
|
||||
longopts, NULL)) != -1)
|
||||
{
|
||||
switch (opt) {
|
||||
case 'c':
|
||||
case 'B':
|
||||
palerain_flags |= palerain_option_setup_partial_root;
|
||||
palerain_flags |= palerain_option_setup_rootful;
|
||||
kpf_flags |= checkrain_option_verbose_boot;
|
||||
break;
|
||||
case 'C':
|
||||
palerain_flags |= palerain_option_setup_rootful;
|
||||
palerain_flags |= palerain_option_setup_rootful_forced;
|
||||
case 'c':
|
||||
palerain_flags |= palerain_option_setup_rootful;
|
||||
kpf_flags |= checkrain_option_verbose_boot;
|
||||
break;
|
||||
case 'p':
|
||||
@@ -249,10 +249,6 @@ int optparse(int argc, char* argv[]) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (checkrain_option_enabled(checkrain_flags, checkrain_option_force_revert) && checkrain_option_enabled(palerain_flags, palerain_option_setup_rootful)) {
|
||||
LOG(LOG_WARNING, "force revert and setup rootful requested at the same time, behaviour here is undefined");
|
||||
}
|
||||
|
||||
snprintf(checkrain_flags_cmd, 0x20, "checkra1n_flags 0x%x", checkrain_flags);
|
||||
snprintf(palerain_flags_cmd, 0x20, "palera1n_flags 0x%x", palerain_flags);
|
||||
snprintf(kpf_flags_cmd, 0x20, "kpf_flags 0x%x", kpf_flags);
|
||||
|
||||
Reference in new issue
Block a user