mirror of
https://github.com/NohamR/pyzule-rw.git
synced 2026-10-11 10:15:35 +00:00
feat: fakesign
This commit is contained in:
@@ -18,11 +18,11 @@ easiest install ever, just `pip install -U git+https://github.com/asdfzxcvbn/pyz
|
||||
|
||||
[] refactor: dont prepare, just copy and fix as you go
|
||||
|
||||
[1] feat: plist operations (-u, -n, -v, -b, -m, -d, -l, -r)
|
||||
[2] feat: plist operations (-n, -v, -b, -m, -l, -r)
|
||||
|
||||
[x] feat: remove watch app
|
||||
|
||||
[] feat: fakesign
|
||||
[x] feat: fakesign
|
||||
|
||||
[] feat: thin binaries
|
||||
|
||||
|
||||
@@ -39,6 +39,10 @@ def main() -> None:
|
||||
"-d", "--enable-documents", action="store_true",
|
||||
help="enable documents support"
|
||||
)
|
||||
parser.add_argument(
|
||||
"-s", "--fakesign", action="store_true",
|
||||
help="fakesign all binaries for use with appsync/trollstore"
|
||||
)
|
||||
|
||||
parser.add_argument(
|
||||
"-c", "--compress", metavar="level", type=int, default=6,
|
||||
|
||||
@@ -47,6 +47,8 @@ def main(parser: ArgumentParser) -> None:
|
||||
app.remove_watch_apps()
|
||||
if args.enable_documents:
|
||||
app.plist.enable_documents()
|
||||
if args.fakesign:
|
||||
app.fakesign_all()
|
||||
|
||||
# create subdirectories if necessary
|
||||
if "/" in args.o:
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import os
|
||||
import shutil
|
||||
from glob import glob
|
||||
|
||||
from .executable import Executable
|
||||
from .plist import Plist
|
||||
@@ -37,3 +38,20 @@ class AppBundle:
|
||||
else:
|
||||
print("[?] watch app not present")
|
||||
|
||||
def fakesign_all(self) -> None:
|
||||
self.executable.fakesign()
|
||||
count = 1
|
||||
|
||||
for ts in sum((
|
||||
glob(f"{self.path}/**/*.appex", recursive=True),
|
||||
glob(f"{self.path}/**/*.framework", recursive=True)
|
||||
), []): # type: ignore
|
||||
pl = Plist(f"{ts}/Info.plist")
|
||||
Executable(f"{ts}/{pl['CFBundleExecutable']}").fakesign()
|
||||
count += 1
|
||||
|
||||
for ts in glob(f"{self.path}/**/*.dylib", recursive=True):
|
||||
Executable(ts).fakesign()
|
||||
count += 1
|
||||
|
||||
print(f"[*] fakesigned \033[96m{count}\033[0m items")
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
lief
|
||||
|
||||
Reference in New Issue
Block a user