Skip to content

Enable developer mode toggle#93

Closed
wynwxst wants to merge 5 commits intoStephenDev0:mainfrom
wynwxst:main
Closed

Enable developer mode toggle#93
wynwxst wants to merge 5 commits intoStephenDev0:mainfrom
wynwxst:main

Conversation

@wynwxst
Copy link
Contributor

@wynwxst wynwxst commented Apr 7, 2025

cc. @jkcoxson ,
enables developer mode though objC bindings and C function when toggled on:
TODO: make it disable developer mode when turned off

@wynwxst
Copy link
Contributor Author

wynwxst commented Apr 7, 2025

Do NOT merge, I am not clear on what the new lockdownd_get_value() now takes in mountDDI


var uniqueChipIDPlist: plist_t?
guard lockdownd_get_value(lockdownClient, "UniqueChipID".cString(using: .utf8), &uniqueChipIDPlist) == IdeviceSuccess else {
guard lockdownd_get_value(lockdownClient, "UniqueChipID".cString(using: .utf8), &uniqueChipIDPlist, nil) == IdeviceSuccess else {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is correct

lockdownd_get_value(client, "DeveloperModeStatus",
"com.apple.security.mac.amfi", &developer_mode_plist);
if (err != IdeviceSuccess) {
fprintf(stderr, "Failed to get product version: %d\n", err);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like the wrong error string, this is a failure to get dev mode status


#include "jit.h"

int enable_developer_mode(TcpProviderHandle *tcp_client){
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There seems to be confusion, lockdown can only return whether it's enabled or not, not enable it. idevice would have to implement amfi to enable developer mode.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see, I'll do that

@wynwxst wynwxst closed this Apr 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants