-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#import <NanoTimeKit/NanoTimeKit.h> #1
Comments
I also can't find anything that would get a dylib called Carousel, and can't find the framework on my computer. Running El Capitan 6 and Watch OS 2 5 |
It's a from the private framework, NanoTimeKit. We need to find a private header dump from a watch device to even build this. I have no clue how make Carousel pick it up though. I've never done jailbreak dev, just regular. |
@carbamide do you have any idea what Carousel even is? Maybe we can figure it out. |
Carousel is the equivalent of SpringBoard for WatchOS. |
Hello @carbamide, do you have a link to download NanoTimeKit header ? |
Seems like this is the dump we need? https://github.com/nickfrey/WatchOS-Headers/tree/master/Device/NanoTimeKit.framework |
Thank's @matthijsotterloo, but I allready include this framework in my project but it doesn't compile. |
Yes also tried that, it doesn't compile because it's missing NanoTimekit.h which is not included in this framework... |
As stated above, NanoTimeKit is an internal framework running on the Watch. To get headers you can either class dump the binary, or simply write them yourself. I do not know how he has gotten Carousel to load the dylib, however. That is something I would be very interested in hearing, purely to satiate my curiosity. |
Carousel is the watchOS equivalent of SpringBoard. It's the app that displays the home screen, notification centre, glances, watch faces etc. I haven't open sourced how I got Carousel to load the dylib. This repo only contains the watch face code and what you'd need to hook once you've got code running in Carousel. |
@hamzasood Would you be willing to share what vector/general starting point you're using to get Carousal to load dylibs? Fully understand you don't want to share all your goodies, though this is something that seems very interesting and I'd love to look into it for myself, though I'm not sure where to start. |
+1 @codyd51 |
@codyd51 I may have found at least a way to load the dylib on the simulator. At the moment I am trying to get the dylib to compile. The NanoTimeKit.h file is pretty much just a file to import everything from the Framework. This can easily be done yourself. |
@DJLectr0 I finally decompiled the Carousel headers and compiled the dylib.... would really appreciate your thoughts on loading it. |
@DJLectr0 Hey, that's better than nothing! Mind divulging how you did that? Maybe we could go digging together and see what we can figure out :-) |
@VedBoon Sure. Could you also share your xcodeproject with me where you got it to compile? (Best would be private because of the NDA) I thought of loading in the Simulator like when you load tweaks in the ios sim (http://sharedinstance.net/2013/10/running-tweaks-in-simulator/) so editing the lanchdaemons of the sim sdk to include the Dylib injection like in the article just instead of springboard the carousel plist. |
@DJLectr0 That post is sorely outdated and does not work on recent versions of the iOS sim. I cannot speak for the Watch sim as I have not tried it, but the current method for loading dylibs into the iOS sim is utilizing optool by @alexzielenski |
@codyd51 Ok did not know that :( So maybe try optool? |
@DJLectr0 Actually, I have. I totally forgot about this earlier, but @EthanArbuckle and I fooled around with loading some dylibs into the Watch sim's Prefs.app - nothing big, mind you; pushing dumb view controllers and changing color schemes. Neat, but it does not help the final goal of getting dylibs loaded onto an actual device. |
@codyd51 Well its a start ;) We could try to load a custom firmware or with the new independent apps look if we can use some methods from some private Frameworks to get it to load the dylib. |
Share your magix hamza |
@codyd51 When I get home, I will try to load some simple dylibs in the Simulator and then look at how to get the watch OS 2 Firmware |
(Addressing each sentence in order) @DJLectr0 Loading a custom firmware isn't in the spirit of what we're trying to achieve IMHO. It's the argument of using Substrate over manually replacing binaries. We can't use private frameworks while sandboxed. Yes, that's kind of the whole idea regarding tweak development ;P |
@codyd51 Yes I know, but if we could load a custom Firmware we could inject a dylib, which is what we are trying here. I know its really manual but it would be a nice start. |
@DJLectr0 @codyd51 Maybe I didn't unsderstand. But we can try to load dylib to carusel with lldb like this http://www.ifans.com/forums/threads/dylib-injection-with-iphone-simulator.109242/ |
@AlexeyBlezeko the problem is that we need to find a way to inject the dylib into carousel on an actual watch. |
@DJLectr0 Can we use gdb on actual watch? |
@AlexeyBelezeko Simple answer: no. The reason is twofold:
|
@codyd51 Not quite true. The DeveloperDiskImage for iOS and watchOS both have debugserver. But it can only attach to processes with the get-task-allow entitlement. |
@Baddaboo Ok just started this back up again got the frameworks that are needed loaded in, I'm still stuck at the NanoTimeKit not found (Got passed before but idk how lol), would we call this progress? |
@RepoEliteARO I'd say make sure that the NanoTimeKit headers you're using are for whatever version of WatchOS you're trying to compile for. I haven't tried the one that @SObS linked to, because the dump I'm using works just fine, but I think some others are running into issues because their headers are for WatchOS 1.0 and they're compiling for 2.0+. Other than that, make sure that your search path is set, the NanoTimeKit framework is included, and, uh, pray. I'm at the point where ld keeps crashing and throwing:
|
@Baddaboo Alright thanks ill check out @SObS links and see what I can do, ill get back to you when things work. Ill fix my search paths and see what else I can get done. Any idea what would be causing that? Update: Just did that fixed the missing "Nano not found" error (starting to remember now :P) now its spewing out a bunch of errors, think most are UIKit errors from what I'm seeing I may have missed something so... |
About UIKit(UIView) and etc: "Missing Headers & Frameworks: … For the most part, you just need to copy the tbd files from the iPhoneOS SDK into the appropriate places in the WatchOS SDK, as well as their headers, then edit the tbd files to include ‘armv7k’. I’m sure somebody will automate this repetitive and thankless job" from here http://blog.steventroughtonsmith.com/post/128957959685/native-uikit-apps-on-apple-watch |
What's the point you all try to compile it when it won't work? The main idea is that this code should be executed by carousel app, without it this code and project are useless. You can just comment out everything and compile an empty dylib to play with, and only after figuring out of how to load that dylib into carousel, it is worth to compile the whole code. |
@angelovAlex The bad thing is that we can't inject the compiled dylib into a real Watch without some tricks. Though I think we can inject the code into a simulator which would be pretty cool too :) |
any progress? :-/ its been almost a year since this was posted :( |
It's been a year since this issue first appeared. Has there been anyone with a solution, or can @hamzasood shed some light on this topic? |
What is the big deal? You can class-dump files on your own from iOS Simulator. I already did that few minutes ago and I will post the project when it's ready and fully working. 👍 |
@DominikBucher12 YES!!! FINALLY!! Please share once you get it working!!! |
@DominikBucher12 Excellent, could we see a proof of concept? How far along do you think you are with it? |
Not sure what all the hubbub is with @DominikBucher12 but he is right: it's not that hard to class-dump the sim headers and get the project to compile. If you need any proof, you can grab the dylib I compiled. Since my school's on Thanksgiving break, I decided to pick up the project again to try to figure out how to inject the library into Carousel. All I've been able to do so far is make my watch crash. I pushed a new repo with the patched frameworks and project I'm working on if you want to see what I'm up to: https://github.com/Baddaboo/WatchYourFaceTest |
Any progress? |
Progress has been very hit-and-miss. I've tried to get Carousel to load the dylib, but debugserver has very little documentation on what it can actually do and there are many points at which I do something that causes my watch to lock up and stop responding to Xcode's debugger until I restart it |
FWIW I even tried swizzling a clockkit function to see if I could get Carousel to execute a dlopen through a complication, but that route seems like a dead-end :/ |
@Baddaboo Thanks, your route now is a kind of good way. |
Few tips on injecting dylibs, a bit old perhaps http://blog.timac.org/?p=761 a bit of theory: |
Anything us noobs can do to help? As a designer, I have great watch faces I could share with everyone if we get this to work! |
@StevenTLBF Likely no. Plus I doubt that this will be usable on a physical device unless we see a watchOS "jailbreak." |
@Shugabuga Hamza demoed it on a physical device though.. fingers crossed that we can figure this out! |
@StevenTLBF I think he has an exploit, as his former projects that also required a jailbreak (especially his live wallpaper example) was demoed on actual devices before a JB if I recall. Plus, how else would we modify Carousel, because if Carousel can be modified without a jailbreak, then that means that SpringBoard could be too. |
@hamzasood any light you can shed? |
I don't think so. We need to include them in Carousel.app, which can't be modified AFAIK. I know recently a dev was able to get the Hermés watchface running on a normal Apple Watch with only a jailbreak, but we'll see... |
@Shugabuga Where did you see the Hermés watch face on a normal Apple Watch? I'm intrigued. |
Here. |
Not sure if anyone is still interested but here's the updated/working repo for use with Simulator. |
@justMaku I am interested, so thanks for the link! |
How can I import this file? I don't understand what you mean with import carousel into the dylib
The text was updated successfully, but these errors were encountered: