Defines | |
#define | LOCKDOWN_E_SUCCESS 0 |
#define | LOCKDOWN_E_INVALID_ARG -1 |
#define | LOCKDOWN_E_INVALID_CONF -2 |
#define | LOCKDOWN_E_PLIST_ERROR -3 |
#define | LOCKDOWN_E_PAIRING_FAILED -4 |
#define | LOCKDOWN_E_SSL_ERROR -5 |
#define | LOCKDOWN_E_DICT_ERROR -6 |
#define | LOCKDOWN_E_START_SERVICE_FAILED -7 |
#define | LOCKDOWN_E_NOT_ENOUGH_DATA -8 |
#define | LOCKDOWN_E_SET_VALUE_PROHIBITED -9 |
#define | LOCKDOWN_E_GET_VALUE_PROHIBITED -10 |
#define | LOCKDOWN_E_REMOVE_VALUE_PROHIBITED -11 |
#define | LOCKDOWN_E_MUX_ERROR -12 |
#define | LOCKDOWN_E_UNKNOWN_ERROR -256 |
Typedefs | |
typedef int16_t | lockdownd_error_t |
typedef struct lockdownd_client_int * | lockdownd_client_t |
Functions | |
lockdownd_error_t | lockdownd_client_new (iphone_device_t device, lockdownd_client_t *client) |
Creates a lockdownd client for the give iPhone. | |
lockdownd_error_t | lockdownd_client_free (lockdownd_client_t client) |
Closes the lockdownd client and does the necessary housekeeping. | |
lockdownd_error_t | lockdownd_query_type (lockdownd_client_t client) |
Initiates the handshake for the lockdown session. | |
lockdownd_error_t | lockdownd_get_value (lockdownd_client_t client, const char *domain, const char *key, plist_t *value) |
Retrieves a preferences plist using an optional domain and/or key name. | |
lockdownd_error_t | lockdownd_set_value (lockdownd_client_t client, const char *domain, const char *key, plist_t value) |
Sets a preferences value using a plist and optional domain and/or key name. | |
lockdownd_error_t | lockdownd_remove_value (lockdownd_client_t client, const char *domain, const char *key) |
Removes a preference node on the device by domain and/or key name. | |
lockdownd_error_t | lockdownd_start_service (lockdownd_client_t client, const char *service, int *port) |
Command to start the desired service. | |
lockdownd_error_t | lockdownd_stop_session (lockdownd_client_t client, const char *session_id) |
Closes the lockdownd communication session, by sending the StopSession Request to the device. | |
lockdownd_error_t | lockdownd_send (lockdownd_client_t client, plist_t plist) |
Sends lockdownd data to the iPhone. | |
lockdownd_error_t | lockdownd_recv (lockdownd_client_t client, plist_t *plist) |
Polls the iPhone for lockdownd data. | |
lockdownd_error_t | lockdownd_pair (lockdownd_client_t client, char *uuid, char *host_id) |
Generates the appropriate keys and pairs the device. | |
lockdownd_error_t | lockdownd_get_device_uuid (lockdownd_client_t control, char **uuid) |
Asks for the device's unique id. | |
lockdownd_error_t | lockdownd_get_device_name (lockdownd_client_t client, char **device_name) |
Askes for the device's name. | |
lockdownd_error_t | lockdownd_enter_recovery (lockdownd_client_t client) |
Tells the device to immediately enter recovery mode. | |
lockdownd_error_t | lockdownd_goodbye (lockdownd_client_t client) |
Performs the Goodbye Request to tell the device the communication session is now closed. |
lockdownd_error_t lockdownd_client_free | ( | lockdownd_client_t | client | ) |
Closes the lockdownd client and does the necessary housekeeping.
client | The lockdown client |
lockdownd_error_t lockdownd_client_new | ( | iphone_device_t | device, | |
lockdownd_client_t * | client | |||
) |
Creates a lockdownd client for the give iPhone.
phone | The iPhone to create a lockdownd client for | |
client | The pointer to the location of the new lockdownd_client |
lockdownd_error_t lockdownd_enter_recovery | ( | lockdownd_client_t | client | ) |
Tells the device to immediately enter recovery mode.
client | The lockdown client |
lockdownd_error_t lockdownd_get_device_name | ( | lockdownd_client_t | client, | |
char ** | device_name | |||
) |
Askes for the device's name.
client | The pointer to the location of the new lockdownd_client |
lockdownd_error_t lockdownd_get_device_uuid | ( | lockdownd_client_t | client, | |
char ** | uuid | |||
) |
Asks for the device's unique id.
Part of the lockdownd handshake.
lockdownd_error_t lockdownd_get_value | ( | lockdownd_client_t | client, | |
const char * | domain, | |||
const char * | key, | |||
plist_t * | value | |||
) |
Retrieves a preferences plist using an optional domain and/or key name.
client | an initialized lockdownd client. | |
domain | the domain to query on or NULL for global domain | |
key | the key name to request or NULL to query for all keys | |
value | a plist node representing the result value node |
lockdownd_error_t lockdownd_goodbye | ( | lockdownd_client_t | client | ) |
Performs the Goodbye Request to tell the device the communication session is now closed.
client | The lockdown client |
lockdownd_error_t lockdownd_pair | ( | lockdownd_client_t | client, | |
char * | uuid, | |||
char * | host_id | |||
) |
Generates the appropriate keys and pairs the device.
It's part of the lockdownd handshake.
lockdownd_error_t lockdownd_query_type | ( | lockdownd_client_t | client | ) |
Initiates the handshake for the lockdown session.
Part of the lockdownd handshake.
client | The lockdownd client |
lockdownd_error_t lockdownd_recv | ( | lockdownd_client_t | client, | |
plist_t * | plist | |||
) |
Polls the iPhone for lockdownd data.
control | The lockdownd client | |
plist | The plist to store the received data |
lockdownd_error_t lockdownd_remove_value | ( | lockdownd_client_t | client, | |
const char * | domain, | |||
const char * | key | |||
) |
Removes a preference node on the device by domain and/or key name.
client | an initialized lockdownd client. | |
domain | the domain to query on or NULL for global domain | |
key | the key name to remove or NULL remove all keys for the current domain |
lockdownd_error_t lockdownd_send | ( | lockdownd_client_t | client, | |
plist_t | plist | |||
) |
Sends lockdownd data to the iPhone.
client | The lockdownd client | |
plist | The plist to send |
lockdownd_error_t lockdownd_set_value | ( | lockdownd_client_t | client, | |
const char * | domain, | |||
const char * | key, | |||
plist_t | value | |||
) |
Sets a preferences value using a plist and optional domain and/or key name.
client | an initialized lockdownd client. | |
domain | the domain to query on or NULL for global domain | |
key | the key name to set the value or NULL to set a value dict plist | |
value | a plist node of any node type representing the value to set |
lockdownd_error_t lockdownd_start_service | ( | lockdownd_client_t | client, | |
const char * | service, | |||
int * | port | |||
) |
Command to start the desired service.
client | The lockdownd client | |
service | The name of the service to start | |
port | The port number the service was started on |
lockdownd_error_t lockdownd_stop_session | ( | lockdownd_client_t | client, | |
const char * | session_id | |||
) |
Closes the lockdownd communication session, by sending the StopSession Request to the device.
control | The lockdown client |