Skip to content

feat(macOS): add Apple TV wireless pairing - #256

Open
castdrian wants to merge 8 commits into
claration:mainfrom
castdrian:feat/apple-tv
Open

feat(macOS): add Apple TV wireless pairing#256
castdrian wants to merge 8 commits into
claration:mainfrom
castdrian:feat/apple-tv

Conversation

@castdrian

@castdrian castdrian commented Sep 13, 2026

Copy link
Copy Markdown

needed to sideload mutube again as it expired on my tv, so here we are I guess, tested and works using 2nd gen 4k atv but someone should probably test a bit more extensiveley across other devices

also fixes the provisioning for atv installs

ssalggnikool
ssalggnikool previously approved these changes Sep 13, 2026
let mut mobile_provision = MobileProvision::load_with_bytes(
profiles.provisioning_profile.encoded_profile.as_ref().to_vec(),
)?;
let requested_entitlements = macho.entitlements().as_ref();

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason why signing code has been touched? At least to me theres no reason why this should've been modified, as well as the API for communicating with developer services. I've tested it before with an ATV4K and it should work fine without these changes.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I figured atv provisioning fields would be nice given full parity and my provisioning profile for the tv was expired therefore handling those cases seemed prudent, but can get rid of that as well

}
}

#[cfg(test)]

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's a lot of unnecessary tests.

Comment thread crates/plume_utils/src/device.rs Outdated
let (pin_sender, pin_receiver) = std::sync::mpsc::sync_channel::<String>(1);
let device_name = device_name.to_string();
let mut pairing_task = tokio::task::spawn_blocking(move || -> Result<(), String> {
let mut child = std::process::Command::new("xcrun")

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We cannot use xcrun at all, many people who use Impactor are not going to be downloading Xcode (which is huge, gigabytes in data) just to be running this.

Comment thread crates/plume_utils/src/device.rs Outdated
} else {
self.name.clone()
};
let output = std::process::Command::new("xcrun")

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can't use any platform specific programs for pairing, use the idevice crate and look at the tools for examples.

Comment thread crates/plume_utils/src/device.rs Outdated
Ok(())
}

#[cfg(test)]

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

More unnecessary tests.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tests are fun :( but they shall disappear

keys
}

fn device_quality(device: &Device) -> usize {

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the point of this?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

usbmuxd shows some bogus device records so tvs show up twice, coredevice seemed better but I reckon just simple dedupes make some more sense

.qh_ensure_device(&team_id_string, &device.name, &device.udid)
.await
.map_err(|e| format!("Failed to ensure device: {}", e))?;
if !device.is_mac {

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mac devices need to be registered to sideload properly. There's many things in code that are done for a reason.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants