diff options
Diffstat (limited to 'src/lockdown.c')
| -rw-r--r-- | src/lockdown.c | 130 |
1 files changed, 71 insertions, 59 deletions
diff --git a/src/lockdown.c b/src/lockdown.c index e882128..5b83fb9 100644 --- a/src/lockdown.c +++ b/src/lockdown.c | |||
| @@ -30,6 +30,8 @@ | |||
| 30 | #include <libtasn1.h> | 30 | #include <libtasn1.h> |
| 31 | #include <gnutls/x509.h> | 31 | #include <gnutls/x509.h> |
| 32 | 32 | ||
| 33 | #include <plist/plist.h> | ||
| 34 | |||
| 33 | const ASN1_ARRAY_TYPE pkcs1_asn1_tab[] = { | 35 | const ASN1_ARRAY_TYPE pkcs1_asn1_tab[] = { |
| 34 | {"PKCS1", 536872976, 0}, | 36 | {"PKCS1", 536872976, 0}, |
| 35 | {0, 1073741836, 0}, | 37 | {0, 1073741836, 0}, |
| @@ -177,10 +179,9 @@ iphone_error_t lockdownd_hello(iphone_lckd_client_t control) | |||
| 177 | int bytes = 0, i = 0; | 179 | int bytes = 0, i = 0; |
| 178 | iphone_error_t ret = IPHONE_E_UNKNOWN_ERROR; | 180 | iphone_error_t ret = IPHONE_E_UNKNOWN_ERROR; |
| 179 | 181 | ||
| 180 | plist_t dict = NULL; | 182 | plist_t dict = plist_new_dict(); |
| 181 | plist_new_dict(&dict); | 183 | plist_add_sub_element(dict, PLIST_KEY, (void *) "Request", strlen("Request")); |
| 182 | 184 | plist_add_sub_element(dict, PLIST_STRING, (void *) "QueryType", strlen("QueryType")); | |
| 183 | plist_add_dict_element(dict, "Request", PLIST_STRING, (void *) "QueryType", strlen("QueryType")); | ||
| 184 | 185 | ||
| 185 | log_debug_msg("lockdownd_hello() called\n"); | 186 | log_debug_msg("lockdownd_hello() called\n"); |
| 186 | char *XML_content = NULL; | 187 | char *XML_content = NULL; |
| @@ -197,14 +198,14 @@ iphone_error_t lockdownd_hello(iphone_lckd_client_t control) | |||
| 197 | 198 | ||
| 198 | ret = iphone_lckd_recv(control, &XML_content, &bytes); | 199 | ret = iphone_lckd_recv(control, &XML_content, &bytes); |
| 199 | log_debug_msg("Receive msg :\nsize : %i\nxml : %s", bytes, XML_content); | 200 | log_debug_msg("Receive msg :\nsize : %i\nxml : %s", bytes, XML_content); |
| 200 | xml_to_plist(XML_content, bytes, &dict); | 201 | plist_from_xml(XML_content, bytes, &dict); |
| 201 | 202 | ||
| 202 | if (!dict) | 203 | if (!dict) |
| 203 | return IPHONE_E_PLIST_ERROR; | 204 | return IPHONE_E_PLIST_ERROR; |
| 204 | 205 | ||
| 205 | plist_t query_node = find_query_node(dict, "Request", "QueryType"); | 206 | plist_t query_node = plist_find_node(dict, PLIST_STRING, "QueryType", strlen("QueryType")); |
| 206 | plist_t result_node = g_node_next_sibling(query_node); | 207 | plist_t result_node = plist_get_next_sibling(query_node); |
| 207 | plist_t value_node = g_node_next_sibling(result_node); | 208 | plist_t value_node = plist_get_next_sibling(result_node); |
| 208 | 209 | ||
| 209 | plist_type result_type; | 210 | plist_type result_type; |
| 210 | plist_type value_type; | 211 | plist_type value_type; |
| @@ -214,8 +215,8 @@ iphone_error_t lockdownd_hello(iphone_lckd_client_t control) | |||
| 214 | uint64_t result_length = 0; | 215 | uint64_t result_length = 0; |
| 215 | uint64_t value_length = 0; | 216 | uint64_t value_length = 0; |
| 216 | 217 | ||
| 217 | get_type_and_value(result_node, &result_type, (void *) (&result_value), &result_length); | 218 | plist_get_type_and_value(result_node, &result_type, (void *) (&result_value), &result_length); |
| 218 | get_type_and_value(value_node, &value_type, (void *) (&value_value), &value_length); | 219 | plist_get_type_and_value(value_node, &value_type, (void *) (&value_value), &value_length); |
| 219 | 220 | ||
| 220 | if (result_type == PLIST_KEY && | 221 | if (result_type == PLIST_KEY && |
| 221 | value_type == PLIST_STRING && !strcmp(result_value, "Result") && !strcmp(value_value, "Success")) { | 222 | value_type == PLIST_STRING && !strcmp(result_value, "Result") && !strcmp(value_value, "Success")) { |
| @@ -247,9 +248,11 @@ iphone_error_t lockdownd_generic_get_value(iphone_lckd_client_t control, char *r | |||
| 247 | iphone_error_t ret = IPHONE_E_UNKNOWN_ERROR; | 248 | iphone_error_t ret = IPHONE_E_UNKNOWN_ERROR; |
| 248 | 249 | ||
| 249 | /* Setup DevicePublicKey request plist */ | 250 | /* Setup DevicePublicKey request plist */ |
| 250 | plist_new_dict(&dict); | 251 | dict = plist_new_dict(); |
| 251 | plist_add_dict_element(dict, req_key, PLIST_STRING, (void *) req_string, strlen(req_string)); | 252 | plist_add_sub_element(dict, PLIST_KEY, (void *) req_key, strlen(req_key)); |
| 252 | plist_add_dict_element(dict, "Request", PLIST_STRING, (void *) "GetValue", strlen("GetValue")); | 253 | plist_add_sub_element(dict, PLIST_STRING, (void *) req_string, strlen(req_string)); |
| 254 | plist_add_sub_element(dict, PLIST_KEY, (void *) "Request", strlen("Request")); | ||
| 255 | plist_add_sub_element(dict, PLIST_STRING, (void *) "GetValue", strlen("GetValue")); | ||
| 253 | plist_to_xml(dict, &XML_content, &length); | 256 | plist_to_xml(dict, &XML_content, &length); |
| 254 | 257 | ||
| 255 | /* send to iPhone */ | 258 | /* send to iPhone */ |
| @@ -271,13 +274,13 @@ iphone_error_t lockdownd_generic_get_value(iphone_lckd_client_t control, char *r | |||
| 271 | if (ret != IPHONE_E_SUCCESS) | 274 | if (ret != IPHONE_E_SUCCESS) |
| 272 | return ret; | 275 | return ret; |
| 273 | 276 | ||
| 274 | xml_to_plist(XML_content, bytes, &dict); | 277 | plist_from_xml(XML_content, bytes, &dict); |
| 275 | if (!dict) | 278 | if (!dict) |
| 276 | return IPHONE_E_PLIST_ERROR; | 279 | return IPHONE_E_PLIST_ERROR; |
| 277 | 280 | ||
| 278 | plist_t query_node = find_query_node(dict, "Request", "GetValue"); | 281 | plist_t query_node = plist_find_node(dict, PLIST_STRING, "GetValue", strlen("GetValue")); |
| 279 | plist_t result_key_node = g_node_next_sibling(query_node); | 282 | plist_t result_key_node = plist_get_next_sibling(query_node); |
| 280 | plist_t result_value_node = g_node_next_sibling(result_key_node); | 283 | plist_t result_value_node = plist_get_next_sibling(result_key_node); |
| 281 | 284 | ||
| 282 | plist_type result_key_type; | 285 | plist_type result_key_type; |
| 283 | plist_type result_value_type; | 286 | plist_type result_value_type; |
| @@ -286,8 +289,8 @@ iphone_error_t lockdownd_generic_get_value(iphone_lckd_client_t control, char *r | |||
| 286 | uint64_t result_length = 0; | 289 | uint64_t result_length = 0; |
| 287 | uint64_t value_length = 0; | 290 | uint64_t value_length = 0; |
| 288 | 291 | ||
| 289 | get_type_and_value(result_key_node, &result_key_type, (void *) (&result_key), &result_length); | 292 | plist_get_type_and_value(result_key_node, &result_key_type, (void *) (&result_key), &result_length); |
| 290 | get_type_and_value(result_value_node, &result_value_type, (void *) (&result_value), &value_length); | 293 | plist_get_type_and_value(result_value_node, &result_value_type, (void *) (&result_value), &value_length); |
| 291 | 294 | ||
| 292 | if (result_key_type == PLIST_KEY && | 295 | if (result_key_type == PLIST_KEY && |
| 293 | result_value_type == PLIST_STRING && !strcmp(result_key, "Result") && !strcmp(result_value, "Success")) { | 296 | result_value_type == PLIST_STRING && !strcmp(result_key, "Result") && !strcmp(result_value, "Success")) { |
| @@ -299,8 +302,8 @@ iphone_error_t lockdownd_generic_get_value(iphone_lckd_client_t control, char *r | |||
| 299 | return IPHONE_E_DICT_ERROR; | 302 | return IPHONE_E_DICT_ERROR; |
| 300 | } | 303 | } |
| 301 | 304 | ||
| 302 | plist_t value_key_node = g_node_next_sibling(result_key_node); | 305 | plist_t value_key_node = plist_get_next_sibling(result_key_node); |
| 303 | plist_t value_value_node = g_node_next_sibling(value_key_node); | 306 | plist_t value_value_node = plist_get_next_sibling(value_key_node); |
| 304 | plist_type value_key_type; | 307 | plist_type value_key_type; |
| 305 | plist_type value_value_type; | 308 | plist_type value_value_type; |
| 306 | char *value_key = NULL; | 309 | char *value_key = NULL; |
| @@ -308,8 +311,8 @@ iphone_error_t lockdownd_generic_get_value(iphone_lckd_client_t control, char *r | |||
| 308 | uint64_t key_length = 0; | 311 | uint64_t key_length = 0; |
| 309 | uint64_t valval_length = 0; | 312 | uint64_t valval_length = 0; |
| 310 | 313 | ||
| 311 | get_type_and_value(value_key_node, &value_key_type, (void *) (&value_key), &key_length); | 314 | plist_get_type_and_value(value_key_node, &value_key_type, (void *) (&value_key), &key_length); |
| 312 | get_type_and_value(value_value_node, &value_value_type, (void *) (&value_value), &valval_length); | 315 | plist_get_type_and_value(value_value_node, &value_value_type, (void *) (&value_value), &valval_length); |
| 313 | 316 | ||
| 314 | if (value_key_type == PLIST_KEY && !strcmp(result_key, "Value")) { | 317 | if (value_key_type == PLIST_KEY && !strcmp(result_key, "Value")) { |
| 315 | log_debug_msg("lockdownd_generic_get_value(): success\n"); | 318 | log_debug_msg("lockdownd_generic_get_value(): success\n"); |
| @@ -438,14 +441,19 @@ iphone_error_t lockdownd_pair_device(iphone_lckd_client_t control, char *uid, ch | |||
| 438 | } | 441 | } |
| 439 | 442 | ||
| 440 | /* Setup Pair request plist */ | 443 | /* Setup Pair request plist */ |
| 441 | plist_new_dict(&dict); | 444 | dict = plist_new_dict(); |
| 442 | plist_add_dict_element(dict, "PairRecord", PLIST_DICT, NULL, 0); | 445 | plist_add_sub_element(dict, PLIST_KEY, (void *) "PairRecord", strlen("PairRecord")); |
| 443 | dict_record = g_node_last_child(dict); | 446 | dict_record = plist_add_sub_element(dict, PLIST_DICT, NULL, 0); |
| 444 | plist_add_dict_element(dict_record, "DeviceCertificate", PLIST_DATA, (void *) device_cert.data, device_cert.size); | 447 | plist_add_sub_element(dict_record, PLIST_KEY, (void *) "DeviceCertificate", strlen("DeviceCertificate")); |
| 445 | plist_add_dict_element(dict_record, "HostCertificate", PLIST_DATA, (void *) host_cert.data, host_cert.size); | 448 | plist_add_sub_element(dict_record, PLIST_DATA, (void *) device_cert.data, device_cert.size); |
| 446 | plist_add_dict_element(dict_record, "HostID", PLIST_STRING, (void *) host_id, strlen(host_id)); | 449 | plist_add_sub_element(dict_record, PLIST_KEY, (void *) "HostCertificate", strlen("HostCertificate")); |
| 447 | plist_add_dict_element(dict_record, "RootCertificate", PLIST_DATA, (void *) root_cert.data, root_cert.size); | 450 | plist_add_sub_element(dict_record, PLIST_DATA, (void *) host_cert.data, host_cert.size); |
| 448 | plist_add_dict_element(dict, "Request", PLIST_STRING, (void *) "Pair", strlen("Pair")); | 451 | plist_add_sub_element(dict_record, PLIST_KEY, (void *) "HostID", strlen("HostID")); |
| 452 | plist_add_sub_element(dict_record, PLIST_STRING, (void *) host_id, strlen(host_id)); | ||
| 453 | plist_add_sub_element(dict_record, PLIST_KEY, (void *) "RootCertificate", strlen("RootCertificate")); | ||
| 454 | plist_add_sub_element(dict_record, PLIST_DATA, (void *) root_cert.data, root_cert.size); | ||
| 455 | plist_add_sub_element(dict_record, PLIST_KEY, (void *) "Request", strlen("Request")); | ||
| 456 | plist_add_sub_element(dict_record, PLIST_STRING, (void *) "Pair", strlen("Pair")); | ||
| 449 | plist_to_xml(dict, &XML_content, &length); | 457 | plist_to_xml(dict, &XML_content, &length); |
| 450 | log_debug_msg("XML Pairing request :\nsize : %i\nxml :\n %s", length, XML_content); | 458 | log_debug_msg("XML Pairing request :\nsize : %i\nxml :\n %s", length, XML_content); |
| 451 | 459 | ||
| @@ -469,13 +477,13 @@ iphone_error_t lockdownd_pair_device(iphone_lckd_client_t control, char *uid, ch | |||
| 469 | log_debug_msg(XML_content); | 477 | log_debug_msg(XML_content); |
| 470 | log_debug_msg("\n\n"); | 478 | log_debug_msg("\n\n"); |
| 471 | 479 | ||
| 472 | xml_to_plist(XML_content, bytes, &dict); | 480 | plist_from_xml(XML_content, bytes, &dict); |
| 473 | if (!dict) | 481 | if (!dict) |
| 474 | return IPHONE_E_PLIST_ERROR; | 482 | return IPHONE_E_PLIST_ERROR; |
| 475 | 483 | ||
| 476 | plist_t query_node = find_query_node(dict, "Request", "Pair"); | 484 | plist_t query_node = plist_find_node(dict, PLIST_STRING, "Pair", strlen("Pair")); |
| 477 | plist_t result_key_node = g_node_next_sibling(query_node); | 485 | plist_t result_key_node = plist_get_next_sibling(query_node); |
| 478 | plist_t result_value_node = g_node_next_sibling(result_key_node); | 486 | plist_t result_value_node = plist_get_next_sibling(result_key_node); |
| 479 | 487 | ||
| 480 | plist_type result_key_type; | 488 | plist_type result_key_type; |
| 481 | plist_type result_value_type; | 489 | plist_type result_value_type; |
| @@ -484,8 +492,8 @@ iphone_error_t lockdownd_pair_device(iphone_lckd_client_t control, char *uid, ch | |||
| 484 | uint64_t key_length = 0; | 492 | uint64_t key_length = 0; |
| 485 | uint64_t val_length = 0; | 493 | uint64_t val_length = 0; |
| 486 | 494 | ||
| 487 | get_type_and_value(result_key_node, &result_key_type, (void *) (&result_key), &key_length); | 495 | plist_get_type_and_value(result_key_node, &result_key_type, (void *) (&result_key), &key_length); |
| 488 | get_type_and_value(result_value_node, &result_value_type, (void *) (&result_value), &val_length); | 496 | plist_get_type_and_value(result_value_node, &result_value_type, (void *) (&result_value), &val_length); |
| 489 | 497 | ||
| 490 | if (result_key_type == PLIST_KEY && | 498 | if (result_key_type == PLIST_KEY && |
| 491 | result_value_type == PLIST_STRING && !strcmp(result_key, "Result") && !strcmp(result_value, "Success")) { | 499 | result_value_type == PLIST_STRING && !strcmp(result_key, "Result") && !strcmp(result_value, "Success")) { |
| @@ -649,9 +657,11 @@ iphone_error_t lockdownd_start_SSL_session(iphone_lckd_client_t control, const c | |||
| 649 | iphone_error_t ret = IPHONE_E_UNKNOWN_ERROR; | 657 | iphone_error_t ret = IPHONE_E_UNKNOWN_ERROR; |
| 650 | 658 | ||
| 651 | /* Setup DevicePublicKey request plist */ | 659 | /* Setup DevicePublicKey request plist */ |
| 652 | plist_new_dict(&dict); | 660 | dict = plist_new_dict(); |
| 653 | plist_add_dict_element(dict, "HostID", PLIST_STRING, (void *) HostID, strlen(HostID)); | 661 | plist_add_sub_element(dict, PLIST_KEY, (void *) "HostID", strlen("HostID")); |
| 654 | plist_add_dict_element(dict, "Request", PLIST_STRING, (void *) "StartSession", strlen("StartSession")); | 662 | plist_add_sub_element(dict, PLIST_STRING, (void *) HostID, strlen(HostID)); |
| 663 | plist_add_sub_element(dict, PLIST_KEY, (void *) "Request", strlen("Request")); | ||
| 664 | plist_add_sub_element(dict, PLIST_STRING, (void *) "StartSession", strlen("StartSession")); | ||
| 655 | plist_to_xml(dict, &XML_content, &length); | 665 | plist_to_xml(dict, &XML_content, &length); |
| 656 | log_debug_msg("Send msg :\nsize : %i\nxml : %s", length, XML_content); | 666 | log_debug_msg("Send msg :\nsize : %i\nxml : %s", length, XML_content); |
| 657 | 667 | ||
| @@ -668,13 +678,13 @@ iphone_error_t lockdownd_start_SSL_session(iphone_lckd_client_t control, const c | |||
| 668 | if (bytes > 0) { | 678 | if (bytes > 0) { |
| 669 | ret = iphone_lckd_recv(control, &XML_content, &bytes); | 679 | ret = iphone_lckd_recv(control, &XML_content, &bytes); |
| 670 | log_debug_msg("Receive msg :\nsize : %i\nxml : %s", bytes, XML_content); | 680 | log_debug_msg("Receive msg :\nsize : %i\nxml : %s", bytes, XML_content); |
| 671 | xml_to_plist(XML_content, bytes, &dict); | 681 | plist_from_xml(XML_content, bytes, &dict); |
| 672 | if (!dict) | 682 | if (!dict) |
| 673 | return IPHONE_E_PLIST_ERROR; | 683 | return IPHONE_E_PLIST_ERROR; |
| 674 | 684 | ||
| 675 | plist_t query_node = find_query_node(dict, "Request", "StartSession"); | 685 | plist_t query_node = plist_find_node(dict, PLIST_STRING, "StartSession", strlen("StartSession")); |
| 676 | plist_t result_key_node = g_node_next_sibling(query_node); | 686 | plist_t result_key_node = plist_get_next_sibling(query_node); |
| 677 | plist_t result_value_node = g_node_next_sibling(result_key_node); | 687 | plist_t result_value_node = plist_get_next_sibling(result_key_node); |
| 678 | 688 | ||
| 679 | plist_type result_key_type; | 689 | plist_type result_key_type; |
| 680 | plist_type result_value_type; | 690 | plist_type result_value_type; |
| @@ -683,8 +693,8 @@ iphone_error_t lockdownd_start_SSL_session(iphone_lckd_client_t control, const c | |||
| 683 | uint64_t key_length = 0; | 693 | uint64_t key_length = 0; |
| 684 | uint64_t val_length = 0; | 694 | uint64_t val_length = 0; |
| 685 | 695 | ||
| 686 | get_type_and_value(result_key_node, &result_key_type, (void *) (&result_key), &key_length); | 696 | plist_get_type_and_value(result_key_node, &result_key_type, (void *) (&result_key), &key_length); |
| 687 | get_type_and_value(result_value_node, &result_value_type, (void *) (&result_value), &val_length); | 697 | plist_get_type_and_value(result_value_node, &result_value_type, (void *) (&result_value), &val_length); |
| 688 | 698 | ||
| 689 | free(XML_content); | 699 | free(XML_content); |
| 690 | XML_content = NULL; | 700 | XML_content = NULL; |
| @@ -886,9 +896,11 @@ iphone_error_t iphone_lckd_start_service(iphone_lckd_client_t client, const char | |||
| 886 | free(host_id); | 896 | free(host_id); |
| 887 | host_id = NULL; | 897 | host_id = NULL; |
| 888 | 898 | ||
| 889 | plist_new_dict(&dict); | 899 | dict = plist_new_dict(); |
| 890 | plist_add_dict_element(dict, "Request", PLIST_STRING, (void *) "StartService", strlen("StartService")); | 900 | plist_add_sub_element(dict, PLIST_KEY, (void *) "Request", strlen("Request")); |
| 891 | plist_add_dict_element(dict, "Service", PLIST_STRING, (void *) service, strlen(service)); | 901 | plist_add_sub_element(dict, PLIST_STRING, (void *) "StartService", strlen("StartService")); |
| 902 | plist_add_sub_element(dict, PLIST_KEY, (void *) "Service", strlen("Service")); | ||
| 903 | plist_add_sub_element(dict, PLIST_STRING, (void *) service, strlen(service)); | ||
| 892 | plist_to_xml(dict, &XML_content, &length); | 904 | plist_to_xml(dict, &XML_content, &length); |
| 893 | 905 | ||
| 894 | /* send to iPhone */ | 906 | /* send to iPhone */ |
| @@ -908,7 +920,7 @@ iphone_error_t iphone_lckd_start_service(iphone_lckd_client_t client, const char | |||
| 908 | if (IPHONE_E_SUCCESS != ret) | 920 | if (IPHONE_E_SUCCESS != ret) |
| 909 | return ret; | 921 | return ret; |
| 910 | 922 | ||
| 911 | xml_to_plist(XML_content, bytes, &dict); | 923 | plist_from_xml(XML_content, bytes, &dict); |
| 912 | if (!dict) | 924 | if (!dict) |
| 913 | return IPHONE_E_PLIST_ERROR; | 925 | return IPHONE_E_PLIST_ERROR; |
| 914 | 926 | ||
| @@ -917,12 +929,12 @@ iphone_error_t iphone_lckd_start_service(iphone_lckd_client_t client, const char | |||
| 917 | return IPHONE_E_NOT_ENOUGH_DATA; | 929 | return IPHONE_E_NOT_ENOUGH_DATA; |
| 918 | else { | 930 | else { |
| 919 | 931 | ||
| 920 | plist_t query_node = find_query_node(dict, "Request", "StartService"); | 932 | plist_t query_node = plist_find_node(dict, PLIST_STRING, "StartService", strlen("StartService")); |
| 921 | plist_t result_key_node = g_node_next_sibling(query_node); | 933 | plist_t result_key_node = plist_get_next_sibling(query_node); |
| 922 | plist_t result_value_node = g_node_next_sibling(result_key_node); | 934 | plist_t result_value_node = plist_get_next_sibling(result_key_node); |
| 923 | 935 | ||
| 924 | plist_t port_key_node = find_node(dict, PLIST_KEY, "Port"); | 936 | plist_t port_key_node = plist_find_node(dict, PLIST_KEY, "Port", strlen("Port")); |
| 925 | plist_t port_value_node = g_node_next_sibling(port_key_node); | 937 | plist_t port_value_node = plist_get_next_sibling(port_key_node); |
| 926 | 938 | ||
| 927 | plist_type result_key_type; | 939 | plist_type result_key_type; |
| 928 | plist_type result_value_type; | 940 | plist_type result_value_type; |
| @@ -937,10 +949,10 @@ iphone_error_t iphone_lckd_start_service(iphone_lckd_client_t client, const char | |||
| 937 | uint64_t port_val_length = 0; | 949 | uint64_t port_val_length = 0; |
| 938 | uint64_t port_value = 0; | 950 | uint64_t port_value = 0; |
| 939 | 951 | ||
| 940 | get_type_and_value(result_key_node, &result_key_type, (void *) (&result_key), &res_key_length); | 952 | plist_get_type_and_value(result_key_node, &result_key_type, (void *) (&result_key), &res_key_length); |
| 941 | get_type_and_value(result_value_node, &result_value_type, (void *) (&result_value), &res_val_length); | 953 | plist_get_type_and_value(result_value_node, &result_value_type, (void *) (&result_value), &res_val_length); |
| 942 | get_type_and_value(port_key_node, &port_key_type, (void *) (&port_key), &port_key_length); | 954 | plist_get_type_and_value(port_key_node, &port_key_type, (void *) (&port_key), &port_key_length); |
| 943 | get_type_and_value(port_value_node, &port_value_type, (void *) (&port_value), &port_val_length); | 955 | plist_get_type_and_value(port_value_node, &port_value_type, (void *) (&port_value), &port_val_length); |
| 944 | 956 | ||
| 945 | if (result_key_type == PLIST_KEY && | 957 | if (result_key_type == PLIST_KEY && |
| 946 | result_value_type == PLIST_STRING && | 958 | result_value_type == PLIST_STRING && |
