summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGravatar Martin Szulecki2010-01-11 13:22:08 +0100
committerGravatar Martin Szulecki2010-01-11 13:22:08 +0100
commit9fc8e73e75a55ba11c784ebdce2b31877ca3f39f (patch)
tree7b399fc6e0ebfc892426e487508e3cd6e79aafcc /src
parentf60d22f4ae41521d33ed85189733c7538ab65794 (diff)
downloadlibimobiledevice-9fc8e73e75a55ba11c784ebdce2b31877ca3f39f.tar.gz
libimobiledevice-9fc8e73e75a55ba11c784ebdce2b31877ca3f39f.tar.bz2
Validate pairing on lockdown client creation to ensure trusted host status
Apparently this is needed for every connection in order to ensure the lockdown value for TrustedHostAttached is true. In effect, this makes the device expose more functionality.
Diffstat (limited to 'src')
-rw-r--r--src/lockdown.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/lockdown.c b/src/lockdown.c
index 1b33250..5c51120 100644
--- a/src/lockdown.c
+++ b/src/lockdown.c
@@ -671,6 +671,9 @@ lockdownd_error_t lockdownd_client_new(iphone_device_t device, lockdownd_client_
if (LOCKDOWN_E_SUCCESS == ret && !userpref_has_device_public_key(client_loc->uuid))
ret = lockdownd_pair(client_loc, host_id);
+ /* in any case, we need to validate pairing to receive trusted host status */
+ ret = lockdownd_validate_pair(client_loc, host_id);
+
if (LOCKDOWN_E_SUCCESS == ret) {
ret = lockdownd_start_ssl_session(client_loc, host_id);
if (LOCKDOWN_E_SUCCESS != ret) {