mirror of
https://github.com/PlayCover/PlayCover.git
synced 2026-04-26 08:15:56 +03:00
[GH-ISSUE #11] 🚩 Support amfi_allow_any_signature=1 instead of amfi_get_out_of_my_way=1 #6
Labels
No labels
UI
app-support
bug
bug
documentation
duplicate
enhancement
game-support
good first issue
help wanted / caution
inactive
invalid
macos-beta
pull-request
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/PlayCover#6
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @devnoname120 on GitHub (Jul 12, 2022).
Original GitHub issue: https://github.com/PlayCover/PlayCover/issues/11
Playcover requires
nvram boot-args amfi_get_out_of_my_way=1but this prevents any DriverKit system extension from loading for example Karabiner Elements. See https://github.com/pqrs-org/Karabiner-Elements/issues/3127 and https://github.com/pqrs-org/Karabiner-Elements/issues/2892#issuecomment-979676759.If I replace this arg with
amfi_allow_any_signature=1, PlayCover shows that PlaySign isn't enabled and most iOS apps crash on start, e.g. Fruitz but Karabiner-Elements works now.See more info about AppleMobileFileIntegrity.
@ghost commented on GitHub (Jul 12, 2022):
While I don't know how to run Karabiner Elements would you mind trying
sudo nvram boot-args="amfi_allow_any_signature=1 ipc_control_port_options=0"and letting me know.@devnoname120 commented on GitHub (Jul 12, 2022):
@roeegh if I remove
-arm64e_preview_abithen Karabiner Elements works as expected but yabai cannot inject in Dock.app:yabai: scripting-addition failed to inject payload into Dock.app!@ghost commented on GitHub (Jul 12, 2022):
It looks like
arm64e_preview_abiis a requirement for yabai.Please revert your boot args to allow both yabai and Karabiner Elements to run.
A new build of PlayCover has been released. Please try PlayCover 1.0.6. It is recommended you reinstall all your apps/games after updating.
@devnoname120 commented on GitHub (Jul 12, 2022):
*Edited to collapse the log 😅
@roeegh I can confirm that with PlayCover 1.0.6 Fruitz crashes on start.
PlayCover log
@ghost commented on GitHub (Jul 12, 2022):
Would you mind sending me the app store link for the app/game? I will do some local testing.
@devnoname120 commented on GitHub (Jul 12, 2022):
@roeegh Sure!
@ghost commented on GitHub (Jul 12, 2022):
I was just able to run the app. One possibility is you have SIP disabled. Is it necessary to keep SIP off to use either yabai and Karabiner Elements?
@devnoname120 commented on GitHub (Jul 12, 2022):
@roeegh
Can you try using this instead?
sudo nvram boot-args="amfi_allow_any_signature=1 ipc_control_port_options=0 -arm64e_preview_abi". Karabiner Elements requires-arm64e_preview_abi.Can you confirm that signing in the app actually works?
yabai requires at least
csrutil disable --with kext --with dtrace --with basesystem(see doc).I'll try to selectively only reenable these parts and see what happens. iirc I disabled everything to try to make PlayCover work.
@devnoname120 commented on GitHub (Jul 12, 2022):
*Edited to collapse the log 😅
@roeegh I can confirm that Fruitz still crashes on launch with this SIP configuration as recommended in yabai's wiki:
This time around I was able to get the coredump:
coredump
@ghost commented on GitHub (Jul 12, 2022):
Launching the app was not an issue. Logging in, however, was not successful. Possibly because I don't have an account made?
@devnoname120 commented on GitHub (Jul 12, 2022):
@roeegh Weird 😳.
What happens if you click “Sign in with phone number”? It will create an account if you don't have one. You may need to set your default browser to “Safari” in the system preferences prior to that.
Can you try with a fresh installation of PlayCover and Fruitz with these SIP params and boot-args already enabled? The issue may be during the installation of the app.
@devnoname120 commented on GitHub (Jul 12, 2022):
Note: if I export to Sideloadly v0.26.3 I can launch the app from the system launcher without issues. But logging in doesn't work just like when PlaySign isn't enabled.
@devnoname120 commented on GitHub (Jul 12, 2022):
Interestingly, if I click on the “Enable PlaySign” button then PlayCover sets my boot args to
amfi_get_out_of_my_way=0x1 ipc_control_port_options=0after which I restart.But installing and launching Fruitz still crashes at launch 🤔
@lixin9311 commented on GitHub (Jul 13, 2022):
I don't think it is about PlaySign.
The App may implement some sort of environment checks. Just like BA.
I need to relax the JB Bypass rule to make BA run.
You can try to poke around
https://github.com/PlayCover/PlayCover/tree/master/PlayCover/Rules
to see if anything changes.
@devnoname120 commented on GitHub (Jul 13, 2022):
@lixin9311 It may be unrelated but with PlayCover version 1.0.1 (or 1.0.2?) login didn't work unless I enabled PlaySign. Likewise, with PlayCover version 1.0.1 (or 1.0.2?) Fruitz didn't crash even using the boot args
sudo nvram boot-args="amfi_allow_any_signature=1 ipc_control_port_options=0 -arm64e_preview_abi"and SIP disabled, so this is likely a regression.@ohaiibuzzle commented on GitHub (Jul 14, 2022):
From what I can tell that is exactly what it does
You can try to change around in the code and see if your flag works correctly.
Also, keep in mind that this is not strictly necessary, you're meant to use it just so you can log in to apps, then turn it off
@devnoname120 commented on GitHub (Jul 14, 2022):
@ohaiibuzzle The main issue is that Fruitz crashes on start even with the following settings:
Any ideas how I could solve this issue? It launched just fine with or without PlaySign using PlayCover 1.0.1 (or 1.0.2?)
I would need to change this as well or PlaySign won't be enabled:
github.com/PlayCover/PlayCover@994effd82f/PlayCover/Utils/SystemConfig.swift (L40)ref:
github.com/PlayCover/PlayCover@4472d021f8/PlayCover/View/SetupView.swift (L123)Fruitz used to work just fine in a previous version:
@devnoname120 commented on GitHub (Jul 14, 2022):
I can confirm that if I enable SIP and empty the bootargs entirely, and I untick the
Enable Jailbreak Bypass (Alpha)setting then Fruitz launches properly with PlayCover 1.0.6. I can't login though.I'll check if it works with PlaySign and then with my custom argument.
@ghost commented on GitHub (Jul 14, 2022):
@devnoname120 Did the app ever run properly at any point in time? on any version of playcover?
@devnoname120 commented on GitHub (Jul 14, 2022):
@roeegh Yes I remember it used to work fine without manually needing to untick the jailbreak box (maybe it was disabled by default before?)
So I can confirm that as long as
Enable Jailbreak Bypass (Alpha)is disabled Fruitz doesn't crash and if I enable PlaySign (csrutil disable+sudo nvram boot-args="amfi_get_out_of_my_way=0x1 ipc_control_port_options=0) then I can also log in.I'll experiment further with
amfi_allow_any_signature=1and-arm64e_preview_abiby modifying the source code and recompiling.@devnoname120 commented on GitHub (Jul 14, 2022):
@roeegh @lixin9311 @ohaiibuzzle OK so I modified the source code as follows:
I recompiled PlayCover from branch
developand I used the PlayTools of release1.0.7. Here are my test results:sudo nvram boot-args="amfi_allow_any_signature=1 ipc_control_port_options=0 -arm64e_preview_abi"— macOS apps launch fine but Fruitz closes immediately on start (no crash).sudo nvram boot-args="amfi_allow_any_signature=1 -arm64e_preview_abi"— samesudo nvram boot-args="amfi_get_out_of_my_way=1 -arm64e_preview_abi"— Fruitz runs/logins properly but most apps can't launch (Chrome, etc.)sudo nvram boot-args="amfi_get_out_of_my_way=1 ipc_control_port_options=0 -arm64e_preview_abi"— Fruitz runs/logins, and macOS apps work, but system extensions don't work (yabai in particular).Sideloadly starts Fruitz just fine withamfi_allow_any_signature=1. Any ideas why PlayCover can't?Edit: PlayCover 1.0.7 can actually also launch Fruitz if I disable
PlaySign. So the problem seems to be thatPlaySigndoesn't work withamfi_allow_any_signature=1…Any ideas why
amfi_allow_any_signature=1is not enough forPlaySign?@ohaiibuzzle commented on GitHub (Jul 14, 2022):
This is very likely due to the fact that
PlaySignalso grants apps private entitlements (eg.com.apple.private.tcc.allow) which are not allowed unless the app is signed by Apple when amfi is turned on (see here)As far as I know
amfi_allow_any_signature=1only disable signature checking on binaries, not granting private entitlements to them@devnoname120 commented on GitHub (Jul 15, 2022):
This is confirmed by the following (source):
@ohaiibuzzle Could you recompile PlayCover with my changes with the official PlayCover certificate? I don't have any dev license. Thank you 🙏
@ohaiibuzzle commented on GitHub (Jul 16, 2022):
The signature for PlayCover itself is not relevant in this context. These entitlements are applied to the app wrapper that are created and installed on the fly by PlayCover. These necessary entitlements belongs to these packages, not PlayCover itself. Signing PlayCover won't change the fact that the packages created will be fakesigned.
The only way to (possibly) do this is somehow sign the resulting app packages with a Developer ID, which, good luck on that
@devnoname120 commented on GitHub (Jul 16, 2022):
I just tried the following settings:
yabaiworks.PlaySignworks.If I remove
amfi_get_out_of_my_way=1thenPlaySignstops working, the rest is the same. Ugh. It's unlikely that any combination ofnvram boot-argswill solve it at all.@ohaiibuzzle commented on GitHub (Jan 18, 2023):
@devnoname120 Just some update. With the introduction of #710 you probably wants to retest your apps with it. It allows SIP to stay on and login to (partially) works. No idea how compatible it will be, but we're improving it
@devnoname120 commented on GitHub (Jan 18, 2023):
@ohaiibuzzle Awesome! Do you have a build I could test?
@ohaiibuzzle commented on GitHub (Jan 18, 2023):
@devnoname120 Sure thing. Here is the latest develop build with the PlayChain patches
After installing your apps, right click on them and open their Settings, then select the Misc tab and enable PlayChain
Note: You will need to use
codesign -fs- --deepto sign this build like the old daysPlayChainDemo.zip
@devnoname120 commented on GitHub (Jan 18, 2023):
@ohaiibuzzle Can confirm that it doesn't work either. I tried with and without PlayChain and visually it's the same result.
I did the following on the downloaded build before running it:
codesign -fs - PlayCover.app --deepxattr -rd com.apple.quarantine /Applications/PlayCover.appInformation
Note that if I use
amfi_get_out_of_my_way=1instead the browser doesn't appear and there is just a field in the app to type in the verification code.@ohaiibuzzle commented on GitHub (Jan 20, 2023):
@devnoname120 That is interesting. Maybe some weird interaction between app deep linking isn't fine yet
That said, logging in via Facebook (which this app do support) appears to works just fine with SIP on, somehow