fix(activation): Fix AFC service, deletescript return, session mutation
Critical: deletescript now uses com.apple.afc2 for root filesystem access. deletescript_run returns -1 on errors. session no longer mutates caller's handshake_response plist. Added plist_mem_free documentation to activation.h. Fixed version parsing to reject negatives. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
4e6f7b70ee
commit
0a02acd634
6 changed files with 64 additions and 27 deletions
|
|
@ -25,8 +25,9 @@ int activation_get_state(device_info_t *dev, char *buf, size_t buf_len);
|
|||
|
||||
/*
|
||||
* activation_get_session_info -- Retrieve the DRM handshake session blob.
|
||||
* On success, *blob_xml is set to a malloc'd XML string and *blob_len to
|
||||
* its length. Caller must free(*blob_xml).
|
||||
* On success, *blob_xml is set to an XML string and *blob_len to its length.
|
||||
* The string is allocated by libplist; caller must free with plist_mem_free(),
|
||||
* NOT free() or plist_free().
|
||||
* Returns 0 on success, -1 on error.
|
||||
*/
|
||||
int activation_get_session_info(device_info_t *dev,
|
||||
|
|
@ -34,8 +35,9 @@ int activation_get_session_info(device_info_t *dev,
|
|||
|
||||
/*
|
||||
* activation_get_info -- Retrieve full activation info from the device.
|
||||
* On success, *info_xml is set to a malloc'd XML string and *info_len to
|
||||
* its length. Caller must free(*info_xml).
|
||||
* On success, *info_xml is set to an XML string and *info_len to its length.
|
||||
* The string is allocated by libplist; caller must free with plist_mem_free(),
|
||||
* NOT free() or plist_free().
|
||||
* Returns 0 on success, -1 on error.
|
||||
*/
|
||||
int activation_get_info(device_info_t *dev,
|
||||
|
|
|
|||
|
|
@ -15,7 +15,18 @@
|
|||
#include "device/device.h"
|
||||
|
||||
/*
|
||||
* afc_connect -- Start the AFC service and return a client handle.
|
||||
* afc_connect_service -- Start an AFC service by name and return a client.
|
||||
* Use "com.apple.afc" for sandboxed access (/var/mobile/Media/) or
|
||||
* "com.apple.afc2" for full root filesystem access (jailbroken).
|
||||
* Caller must call afc_disconnect() when done.
|
||||
* Returns 0 on success, -1 on error.
|
||||
*/
|
||||
int afc_connect_service(device_info_t *dev, afc_client_t *client,
|
||||
const char *service_name);
|
||||
|
||||
/*
|
||||
* afc_connect -- Start the default AFC service ("com.apple.afc").
|
||||
* Convenience wrapper around afc_connect_service().
|
||||
* Caller must call afc_disconnect() when done.
|
||||
* Returns 0 on success, -1 on error.
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -12,9 +12,9 @@
|
|||
#include "device/device.h"
|
||||
|
||||
typedef struct {
|
||||
int ios_major;
|
||||
int ios_minor;
|
||||
int ios_patch;
|
||||
unsigned int ios_major;
|
||||
unsigned int ios_minor;
|
||||
unsigned int ios_patch;
|
||||
} ios_version_t;
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue