summaryrefslogtreecommitdiffstats
path: root/dev
diff options
context:
space:
mode:
Diffstat (limited to 'dev')
-rw-r--r--dev/afccheck.c15
-rw-r--r--dev/iphone_id.c9
-rw-r--r--dev/iphoneinfo.c17
-rw-r--r--dev/lckdclient.c29
-rw-r--r--dev/main.c35
-rw-r--r--dev/msyncclient.c12
-rw-r--r--dev/syslog_relay.c9
7 files changed, 69 insertions, 57 deletions
diff --git a/dev/afccheck.c b/dev/afccheck.c
index b107437..9174e32 100644
--- a/dev/afccheck.c
+++ b/dev/afccheck.c
@@ -25,6 +25,7 @@
25#include <glib.h> 25#include <glib.h>
26 26
27#include <libiphone/libiphone.h> 27#include <libiphone/libiphone.h>
28#include <libiphone/lockdown.h>
28#include <libiphone/afc.h> 29#include <libiphone/afc.h>
29 30
30#define BUFFER_SIZE 20000 31#define BUFFER_SIZE 20000
@@ -40,10 +41,10 @@ typedef struct {
40void check_afc(gpointer data) 41void check_afc(gpointer data)
41{ 42{
42 //prepare a buffer 43 //prepare a buffer
43 int buffersize = BUFFER_SIZE * sizeof(int); 44 unsigned int buffersize = BUFFER_SIZE * sizeof(unsigned int);
44 int *buf = (int *) malloc(buffersize); 45 int *buf = (int *) malloc(buffersize);
45 int *buf2 = (int *) malloc(buffersize); 46 int *buf2 = (int *) malloc(buffersize);
46 int bytes = 0; 47 unsigned int bytes = 0;
47 //fill buffer 48 //fill buffer
48 int i = 0; 49 int i = 0;
49 for (i = 0; i < BUFFER_SIZE; i++) { 50 for (i = 0; i < BUFFER_SIZE; i++) {
@@ -84,7 +85,7 @@ void check_afc(gpointer data)
84 85
85int main(int argc, char *argv[]) 86int main(int argc, char *argv[])
86{ 87{
87 iphone_lckd_client_t control = NULL; 88 lockdownd_client_t client = NULL;
88 iphone_device_t phone = NULL; 89 iphone_device_t phone = NULL;
89 GError *err; 90 GError *err;
90 int port = 0; 91 int port = 0;
@@ -95,13 +96,13 @@ int main(int argc, char *argv[])
95 return 1; 96 return 1;
96 } 97 }
97 98
98 if (IPHONE_E_SUCCESS != iphone_lckd_new_client(phone, &control)) { 99 if (IPHONE_E_SUCCESS != lockdownd_new_client(phone, &client)) {
99 iphone_free_device(phone); 100 iphone_free_device(phone);
100 return 1; 101 return 1;
101 } 102 }
102 103
103 if (IPHONE_E_SUCCESS == iphone_lckd_start_service(control, "com.apple.afc", &port) && !port) { 104 if (IPHONE_E_SUCCESS == lockdownd_start_service(client, "com.apple.afc", &port) && !port) {
104 iphone_lckd_free_client(control); 105 lockdownd_free_client(client);
105 iphone_free_device(phone); 106 iphone_free_device(phone);
106 fprintf(stderr, "Something went wrong when starting AFC."); 107 fprintf(stderr, "Something went wrong when starting AFC.");
107 return 1; 108 return 1;
@@ -128,7 +129,7 @@ int main(int argc, char *argv[])
128 } 129 }
129 130
130 131
131 iphone_lckd_free_client(control); 132 lockdownd_free_client(client);
132 iphone_free_device(phone); 133 iphone_free_device(phone);
133 134
134 return 0; 135 return 0;
diff --git a/dev/iphone_id.c b/dev/iphone_id.c
index c191608..15081f0 100644
--- a/dev/iphone_id.c
+++ b/dev/iphone_id.c
@@ -3,6 +3,7 @@
3#include <stdlib.h> 3#include <stdlib.h>
4#include <getopt.h> 4#include <getopt.h>
5#include <libiphone/libiphone.h> 5#include <libiphone/libiphone.h>
6#include <libiphone/lockdown.h>
6#include <usbmuxd.h> 7#include <usbmuxd.h>
7 8
8static void usage() 9static void usage()
@@ -18,7 +19,7 @@ static void usage()
18int main(int argc, char **argv) 19int main(int argc, char **argv)
19{ 20{
20 iphone_device_t phone = NULL; 21 iphone_device_t phone = NULL;
21 iphone_lckd_client_t control = NULL; 22 lockdownd_client_t client = NULL;
22 usbmuxd_scan_result *dev_list; 23 usbmuxd_scan_result *dev_list;
23 char *devname = NULL; 24 char *devname = NULL;
24 int ret = 0; 25 int ret = 0;
@@ -67,18 +68,18 @@ int main(int argc, char **argv)
67 return -2; 68 return -2;
68 } 69 }
69 70
70 if (IPHONE_E_SUCCESS != iphone_lckd_new_client(phone, &control)) { 71 if (IPHONE_E_SUCCESS != lockdownd_new_client(phone, &client)) {
71 iphone_free_device(phone); 72 iphone_free_device(phone);
72 fprintf(stderr, "ERROR: Connecting to device failed!\n"); 73 fprintf(stderr, "ERROR: Connecting to device failed!\n");
73 return -2; 74 return -2;
74 } 75 }
75 76
76 if ((IPHONE_E_SUCCESS != lockdownd_get_device_name(control, &devname)) || !devname) { 77 if ((IPHONE_E_SUCCESS != lockdownd_get_device_name(client, &devname)) || !devname) {
77 fprintf(stderr, "ERROR: Could not get device name!\n"); 78 fprintf(stderr, "ERROR: Could not get device name!\n");
78 ret = -2; 79 ret = -2;
79 } 80 }
80 81
81 iphone_lckd_free_client(control); 82 lockdownd_free_client(client);
82 iphone_free_device(phone); 83 iphone_free_device(phone);
83 84
84 if (ret == 0) { 85 if (ret == 0) {
diff --git a/dev/iphoneinfo.c b/dev/iphoneinfo.c
index 18ee055..7c823e6 100644
--- a/dev/iphoneinfo.c
+++ b/dev/iphoneinfo.c
@@ -25,6 +25,7 @@
25#include <stdlib.h> 25#include <stdlib.h>
26 26
27#include <libiphone/libiphone.h> 27#include <libiphone/libiphone.h>
28#include <libiphone/lockdown.h>
28 29
29#define FORMAT_KEY_VALUE 1 30#define FORMAT_KEY_VALUE 1
30#define FORMAT_XML 2 31#define FORMAT_XML 2
@@ -45,13 +46,13 @@ static const char *domains[] = {
45 46
46int is_domain_known(char *domain); 47int is_domain_known(char *domain);
47void print_usage(int argc, char **argv); 48void print_usage(int argc, char **argv);
48void print_lckd_request_result(iphone_lckd_client_t control, const char *domain, const char *request, const char *key, int format); 49void print_lckd_request_result(lockdownd_client_t client, const char *domain, const char *request, const char *key, int format);
49void plist_node_to_string(plist_t *node); 50void plist_node_to_string(plist_t *node);
50void plist_children_to_string(plist_t *node); 51void plist_children_to_string(plist_t *node);
51 52
52int main(int argc, char *argv[]) 53int main(int argc, char *argv[])
53{ 54{
54 iphone_lckd_client_t control = NULL; 55 lockdownd_client_t client = NULL;
55 iphone_device_t phone = NULL; 56 iphone_device_t phone = NULL;
56 iphone_error_t ret = IPHONE_E_UNKNOWN_ERROR; 57 iphone_error_t ret = IPHONE_E_UNKNOWN_ERROR;
57 int i; 58 int i;
@@ -128,17 +129,17 @@ int main(int argc, char *argv[])
128 } 129 }
129 } 130 }
130 131
131 if (IPHONE_E_SUCCESS != iphone_lckd_new_client(phone, &control)) { 132 if (IPHONE_E_SUCCESS != lockdownd_new_client(phone, &client)) {
132 iphone_free_device(phone); 133 iphone_free_device(phone);
133 return -1; 134 return -1;
134 } 135 }
135 136
136 /* run query and output information */ 137 /* run query and output information */
137 print_lckd_request_result(control, domain, "GetValue", key, format); 138 print_lckd_request_result(client, domain, "GetValue", key, format);
138 139
139 if (domain != NULL) 140 if (domain != NULL)
140 free(domain); 141 free(domain);
141 iphone_lckd_free_client(control); 142 lockdownd_free_client(client);
142 iphone_free_device(phone); 143 iphone_free_device(phone);
143 144
144 return 0; 145 return 0;
@@ -248,7 +249,7 @@ void plist_children_to_string(plist_t *node)
248 } 249 }
249} 250}
250 251
251void print_lckd_request_result(iphone_lckd_client_t control, const char *domain, const char *request, const char *key, int format) { 252void print_lckd_request_result(lockdownd_client_t client, const char *domain, const char *request, const char *key, int format) {
252 char *xml_doc = NULL; 253 char *xml_doc = NULL;
253 char *s = NULL; 254 char *s = NULL;
254 uint32_t xml_length = 0; 255 uint32_t xml_length = 0;
@@ -266,11 +267,11 @@ void print_lckd_request_result(iphone_lckd_client_t control, const char *domain,
266 plist_add_sub_key_el(node, "Request"); 267 plist_add_sub_key_el(node, "Request");
267 plist_add_sub_string_el(node, request); 268 plist_add_sub_string_el(node, request);
268 269
269 ret = iphone_lckd_send(control, node); 270 ret = lockdownd_send(client, node);
270 if (ret == IPHONE_E_SUCCESS) { 271 if (ret == IPHONE_E_SUCCESS) {
271 plist_free(node); 272 plist_free(node);
272 node = NULL; 273 node = NULL;
273 ret = iphone_lckd_recv(control, &node); 274 ret = lockdownd_recv(client, &node);
274 if (ret == IPHONE_E_SUCCESS) { 275 if (ret == IPHONE_E_SUCCESS) {
275 /* seek to value node */ 276 /* seek to value node */
276 for ( 277 for (
diff --git a/dev/lckdclient.c b/dev/lckdclient.c
index c96f052..e197002 100644
--- a/dev/lckdclient.c
+++ b/dev/lckdclient.c
@@ -27,12 +27,11 @@
27#include <readline/history.h> 27#include <readline/history.h>
28 28
29#include <libiphone/libiphone.h> 29#include <libiphone/libiphone.h>
30 30#include <libiphone/lockdown.h>
31 31
32int main(int argc, char *argv[]) 32int main(int argc, char *argv[])
33{ 33{
34 int bytes = 0, port = 0, i = 0; 34 lockdownd_client_t client = NULL;
35 iphone_lckd_client_t control = NULL;
36 iphone_device_t phone = NULL; 35 iphone_device_t phone = NULL;
37 36
38 iphone_set_debug(1); 37 iphone_set_debug(1);
@@ -42,13 +41,13 @@ int main(int argc, char *argv[])
42 return -1; 41 return -1;
43 } 42 }
44 43
45 if (IPHONE_E_SUCCESS != iphone_lckd_new_client(phone, &control)) { 44 if (IPHONE_E_SUCCESS != lockdownd_new_client(phone, &client)) {
46 iphone_free_device(phone); 45 iphone_free_device(phone);
47 return -1; 46 return -1;
48 } 47 }
49 48
50 char *uid = NULL; 49 char *uid = NULL;
51 if (IPHONE_E_SUCCESS == lockdownd_get_device_uid(control, &uid)) { 50 if (IPHONE_E_SUCCESS == lockdownd_get_device_uid(client, &uid)) {
52 printf("DeviceUniqueID : %s\n", uid); 51 printf("DeviceUniqueID : %s\n", uid);
53 free(uid); 52 free(uid);
54 } 53 }
@@ -74,17 +73,25 @@ int main(int argc, char *argv[])
74 if (!strcmp(*args, "quit")) 73 if (!strcmp(*args, "quit"))
75 loop = FALSE; 74 loop = FALSE;
76 75
77 if (!strcmp(*args, "get") && len == 3) { 76 if (!strcmp(*args, "get") && len >= 2) {
78 char *value = NULL; 77 plist_t *value = NULL;
79 if (IPHONE_E_SUCCESS == lockdownd_generic_get_value(control, *(args + 1), *(args + 2), &value)) 78 if (IPHONE_E_SUCCESS == lockdownd_get_value(client, len == 3 ? *(args + 1):NULL, len == 3 ? *(args + 2):*(args + 1), &value))
80 printf("Success : value = %s\n", value); 79 {
80 char *xml = NULL;
81 uint32_t length;
82 plist_to_xml(value, &xml, &length);
83 printf("Success : value = %s\n", xml);
84
85 free(xml);
86 free(value);
87 }
81 else 88 else
82 printf("Error\n"); 89 printf("Error\n");
83 } 90 }
84 91
85 if (!strcmp(*args, "start") && len == 2) { 92 if (!strcmp(*args, "start") && len == 2) {
86 int port = 0; 93 int port = 0;
87 iphone_lckd_start_service(control, *(args + 1), &port); 94 lockdownd_start_service(client, *(args + 1), &port);
88 printf("%i\n", port); 95 printf("%i\n", port);
89 } 96 }
90 } 97 }
@@ -94,7 +101,7 @@ int main(int argc, char *argv[])
94 cmd = NULL; 101 cmd = NULL;
95 } 102 }
96 clear_history(); 103 clear_history();
97 iphone_lckd_free_client(control); 104 lockdownd_free_client(client);
98 iphone_free_device(phone); 105 iphone_free_device(phone);
99 106
100 return 0; 107 return 0;
diff --git a/dev/main.c b/dev/main.c
index d39baa7..cf7dbaa 100644
--- a/dev/main.c
+++ b/dev/main.c
@@ -23,25 +23,27 @@
23#include <string.h> 23#include <string.h>
24#include <errno.h> 24#include <errno.h>
25#include <usb.h> 25#include <usb.h>
26#include <glib.h>
26 27
27#include <libiphone/libiphone.h> 28#include <libiphone/libiphone.h>
29#include <libiphone/lockdown.h>
28#include <libiphone/afc.h> 30#include <libiphone/afc.h>
29#include <libiphone/notification_proxy.h> 31#include <libiphone/notification_proxy.h>
30#include "../src/utils.h" 32#include "../src/utils.h"
31 33
32void notifier(const char *notification) 34static void notifier(const char *notification)
33{ 35{
34 printf("---------------------------------------------------------\n"); 36 printf("---------------------------------------------------------\n");
35 printf("------> Notification received: %s\n", notification); 37 printf("------> Notification received: %s\n", notification);
36 printf("---------------------------------------------------------\n"); 38 printf("---------------------------------------------------------\n");
37} 39}
38 40
39void perform_notification(iphone_device_t phone, iphone_lckd_client_t control, const char *notification) 41static void perform_notification(iphone_device_t phone, lockdownd_client_t client, const char *notification)
40{ 42{
41 int nport = 0; 43 int nport = 0;
42 np_client_t np; 44 np_client_t np;
43 45
44 iphone_lckd_start_service(control, "com.apple.mobile.notification_proxy", &nport); 46 lockdownd_start_service(client, "com.apple.mobile.notification_proxy", &nport);
45 if (nport) { 47 if (nport) {
46 printf("::::::::::::::: np was started ::::::::::::\n"); 48 printf("::::::::::::::: np was started ::::::::::::\n");
47 np_new_client(phone, nport, &np); 49 np_new_client(phone, nport, &np);
@@ -57,9 +59,10 @@ void perform_notification(iphone_device_t phone, iphone_lckd_client_t control, c
57 59
58int main(int argc, char *argv[]) 60int main(int argc, char *argv[])
59{ 61{
60 int bytes = 0, port = 0, i = 0; 62 unsigned int bytes = 0;
63 int port = 0, i = 0;
61 int npp; 64 int npp;
62 iphone_lckd_client_t control = NULL; 65 lockdownd_client_t client = NULL;
63 iphone_device_t phone = NULL; 66 iphone_device_t phone = NULL;
64 uint64_t lockfile = 0; 67 uint64_t lockfile = 0;
65 np_client_t gnp = NULL; 68 np_client_t gnp = NULL;
@@ -77,32 +80,32 @@ int main(int argc, char *argv[])
77 return -1; 80 return -1;
78 } 81 }
79 82
80 if (IPHONE_E_SUCCESS != iphone_lckd_new_client(phone, &control)) { 83 if (IPHONE_E_SUCCESS != lockdownd_new_client(phone, &client)) {
81 iphone_free_device(phone); 84 iphone_free_device(phone);
82 printf("Exiting.\n"); 85 printf("Exiting.\n");
83 return -1; 86 return -1;
84 } 87 }
85 88
86 char *uid = NULL; 89 char *uid = NULL;
87 if (IPHONE_E_SUCCESS == lockdownd_get_device_uid(control, &uid)) { 90 if (IPHONE_E_SUCCESS == lockdownd_get_device_uid(client, &uid)) {
88 printf("DeviceUniqueID : %s\n", uid); 91 printf("DeviceUniqueID : %s\n", uid);
89 free(uid); 92 free(uid);
90 } 93 }
91 94
92 95
93 char *nnn = NULL; 96 char *nnn = NULL;
94 if (IPHONE_E_SUCCESS == lockdownd_get_device_name(control, &nnn)) { 97 if (IPHONE_E_SUCCESS == lockdownd_get_device_name(client, &nnn)) {
95 printf("DeviceName : %s\n", nnn); 98 printf("DeviceName : %s\n", nnn);
96 free(nnn); 99 free(nnn);
97 } 100 }
98 101
99 iphone_lckd_start_service(control, "com.apple.afc", &port); 102 lockdownd_start_service(client, "com.apple.afc", &port);
100 103
101 if (port) { 104 if (port) {
102 afc_client_t afc = NULL; 105 afc_client_t afc = NULL;
103 afc_new_client(phone, port, &afc); 106 afc_new_client(phone, port, &afc);
104 if (afc) { 107 if (afc) {
105 iphone_lckd_start_service(control, "com.apple.mobile.notification_proxy", &npp); 108 lockdownd_start_service(client, "com.apple.mobile.notification_proxy", &npp);
106 if (npp) { 109 if (npp) {
107 printf("Notification Proxy started.\n"); 110 printf("Notification Proxy started.\n");
108 np_new_client(phone, npp, &gnp); 111 np_new_client(phone, npp, &gnp);
@@ -120,14 +123,14 @@ int main(int argc, char *argv[])
120 np_set_notify_callback(gnp, notifier); 123 np_set_notify_callback(gnp, notifier);
121 } 124 }
122 125
123 perform_notification(phone, control, NP_SYNC_WILL_START); 126 perform_notification(phone, client, NP_SYNC_WILL_START);
124 127
125 afc_open_file(afc, "/com.apple.itunes.lock_sync", AFC_FOPEN_RW, &lockfile); 128 afc_open_file(afc, "/com.apple.itunes.lock_sync", AFC_FOPEN_RW, &lockfile);
126 if (lockfile) { 129 if (lockfile) {
127 printf("locking file\n"); 130 printf("locking file\n");
128 afc_lock_file(afc, lockfile, 2 | 4); 131 afc_lock_file(afc, lockfile, 2 | 4);
129 132
130 perform_notification(phone, control, NP_SYNC_DID_START); 133 perform_notification(phone, client, NP_SYNC_DID_START);
131 } 134 }
132 135
133 char **dirs = NULL; 136 char **dirs = NULL;
@@ -164,10 +167,10 @@ int main(int argc, char *argv[])
164 167
165 if (IPHONE_E_SUCCESS == 168 if (IPHONE_E_SUCCESS ==
166 afc_open_file(afc, "/readme.libiphone.fx", AFC_FOPEN_RDONLY, &my_file) && my_file) { 169 afc_open_file(afc, "/readme.libiphone.fx", AFC_FOPEN_RDONLY, &my_file) && my_file) {
167 printf("A file size: %i\n", fsize); 170 printf("A file size: %llu\n", fsize);
168 char *file_data = (char *) malloc(sizeof(char) * fsize); 171 char *file_data = (char *) malloc(sizeof(char) * fsize);
169 afc_read_file(afc, my_file, file_data, fsize, &bytes); 172 afc_read_file(afc, my_file, file_data, fsize, &bytes);
170 if (bytes >= 0) { 173 if (bytes > 0) {
171 printf("The file's data:\n"); 174 printf("The file's data:\n");
172 fwrite(file_data, 1, bytes, stdout); 175 fwrite(file_data, 1, bytes, stdout);
173 } 176 }
@@ -218,8 +221,6 @@ int main(int argc, char *argv[])
218 } 221 }
219 222
220 if (gnp && lockfile) { 223 if (gnp && lockfile) {
221 char *noti;
222
223 printf("XXX sleeping\n"); 224 printf("XXX sleeping\n");
224 sleep(5); 225 sleep(5);
225 226
@@ -244,7 +245,7 @@ int main(int argc, char *argv[])
244 245
245 printf("All done.\n"); 246 printf("All done.\n");
246 247
247 iphone_lckd_free_client(control); 248 lockdownd_free_client(client);
248 iphone_free_device(phone); 249 iphone_free_device(phone);
249 250
250 return 0; 251 return 0;
diff --git a/dev/msyncclient.c b/dev/msyncclient.c
index e3bb0c2..e06a5fe 100644
--- a/dev/msyncclient.c
+++ b/dev/msyncclient.c
@@ -25,12 +25,12 @@
25#include <usb.h> 25#include <usb.h>
26 26
27#include <libiphone/libiphone.h> 27#include <libiphone/libiphone.h>
28 28#include <libiphone/lockdown.h>
29 29
30int main(int argc, char *argv[]) 30int main(int argc, char *argv[])
31{ 31{
32 int bytes = 0, port = 0, i = 0; 32 int port = 0;
33 iphone_lckd_client_t control = NULL; 33 lockdownd_client_t client = NULL;
34 iphone_device_t phone = NULL; 34 iphone_device_t phone = NULL;
35 35
36 if (argc > 1 && !strcasecmp(argv[1], "--debug")) 36 if (argc > 1 && !strcasecmp(argv[1], "--debug"))
@@ -42,12 +42,12 @@ int main(int argc, char *argv[])
42 return -1; 42 return -1;
43 } 43 }
44 44
45 if (IPHONE_E_SUCCESS != iphone_lckd_new_client(phone, &control)) { 45 if (IPHONE_E_SUCCESS != lockdownd_new_client(phone, &client)) {
46 iphone_free_device(phone); 46 iphone_free_device(phone);
47 return -1; 47 return -1;
48 } 48 }
49 49
50 iphone_lckd_start_service(control, "com.apple.mobilesync", &port); 50 lockdownd_start_service(client, "com.apple.mobilesync", &port);
51 51
52 if (port) { 52 if (port) {
53 iphone_msync_client_t msync = NULL; 53 iphone_msync_client_t msync = NULL;
@@ -62,7 +62,7 @@ int main(int argc, char *argv[])
62 62
63 printf("All done.\n"); 63 printf("All done.\n");
64 64
65 iphone_lckd_free_client(control); 65 lockdownd_free_client(client);
66 iphone_free_device(phone); 66 iphone_free_device(phone);
67 67
68 return 0; 68 return 0;
diff --git a/dev/syslog_relay.c b/dev/syslog_relay.c
index 6698653..a93e85b 100644
--- a/dev/syslog_relay.c
+++ b/dev/syslog_relay.c
@@ -27,6 +27,7 @@
27#include <stdlib.h> 27#include <stdlib.h>
28 28
29#include <libiphone/libiphone.h> 29#include <libiphone/libiphone.h>
30#include <libiphone/lockdown.h>
30#include <usbmuxd.h> 31#include <usbmuxd.h>
31 32
32static int quit_flag = 0; 33static int quit_flag = 0;
@@ -44,7 +45,7 @@ static void clean_exit(int sig)
44 45
45int main(int argc, char *argv[]) 46int main(int argc, char *argv[])
46{ 47{
47 iphone_lckd_client_t control = NULL; 48 lockdownd_client_t client = NULL;
48 iphone_device_t phone = NULL; 49 iphone_device_t phone = NULL;
49 iphone_error_t ret = IPHONE_E_UNKNOWN_ERROR; 50 iphone_error_t ret = IPHONE_E_UNKNOWN_ERROR;
50 int i; 51 int i;
@@ -99,15 +100,15 @@ int main(int argc, char *argv[])
99 } 100 }
100 } 101 }
101 102
102 if (IPHONE_E_SUCCESS != iphone_lckd_new_client(phone, &control)) { 103 if (IPHONE_E_SUCCESS != lockdownd_new_client(phone, &client)) {
103 iphone_free_device(phone); 104 iphone_free_device(phone);
104 return -1; 105 return -1;
105 } 106 }
106 107
107 /* start syslog_relay service and retrieve port */ 108 /* start syslog_relay service and retrieve port */
108 ret = iphone_lckd_start_service(control, "com.apple.syslog_relay", &port); 109 ret = lockdownd_start_service(client, "com.apple.syslog_relay", &port);
109 if ((ret == IPHONE_E_SUCCESS) && port) { 110 if ((ret == IPHONE_E_SUCCESS) && port) {
110 iphone_lckd_free_client(control); 111 lockdownd_free_client(client);
111 112
112 /* connect to socket relay messages */ 113 /* connect to socket relay messages */
113 114