The secrets of Apple Lightning - Part 1

2023 ж. 10 Ақп.
819 506 Рет қаралды

Apple's proprietary Lightning connector is very well known. But do you know how it works? How is a cable authenticated? What can you do with Lightning? In this video we dive into the details of Apple's Lightning protocol - also known as SDQ and IDBUS!
Links:
- Twitter: / ghidraninja
- Patreon: / stacksmashing
- Nyan Satan's Lightning page: nyansatan.github.io/lightning/
- My DEF CON talk on Lightning: • DEF CON 30 - stacksmas...
- Saleae Logic Analyzer Plugin: github.com/nezza/SDQAnalyzer

Пікірлер
  • Like all true professionals, you make it look so easy! Can't wait for part 2!

    @JohnnyUtah488@JohnnyUtah488 Жыл бұрын
    • It is easy, tho.

      @xy4489@xy4489 Жыл бұрын
    • @@xy4489 only for professionals

      @tomikun8057@tomikun8057 Жыл бұрын
    • @@xy4489it is not

      @CloroxBleach0@CloroxBleach0 Жыл бұрын
    • part 2 please!??

      @DeyaEldeen1@DeyaEldeen1 Жыл бұрын
    • @@tomikun8057not really he just showed you how to do it

      @vxgamer8505@vxgamer850510 ай бұрын
  • let me guess its just USB that is missing U

    @DodoLP@DodoLP Жыл бұрын
    • They should've called it the ASB cable, Apple Serial Bus. At least that would be honest because it's not fast nor universal.

      @Leonard_MT@Leonard_MT Жыл бұрын
    • @@Leonard_MT shouldn't it then be called adb?

      @RC2225@RC2225 Жыл бұрын
    • @@RC2225 not to be confused with Android Debug Bridge

      @lesoup-mxd@lesoup-mxd Жыл бұрын
    • @@RC2225 Apple already made a connector called Apple Desktop Bus (ADB) and it was used for keyboards and mice.

      @WalterMan@WalterMan Жыл бұрын
    • @@RC2225 What would the 'd' be short for?

      @wesleymays1931@wesleymays1931 Жыл бұрын
  • stacksmashing: See you again soon * Five months later... *

    @rikschaaf@rikschaaf9 ай бұрын
    • Its been six now

      @Tyranosaurus_Xer@Tyranosaurus_Xer2 ай бұрын
    • 😂😂

      @hampus23@hampus2313 күн бұрын
  • Excellent instructions/explanations. Your voice clarity,tempo, and video presentation for some reason makes it easier to understand, learn, while also retaining the info. I had to sub and comment with my thanks for your work and expertise for me the layman.

    @ballsdeepgamingcommunity9928@ballsdeepgamingcommunity99286 ай бұрын
  • It would be interesting to see the results from cheap knock-off cables and other 3rd party cables to see what they spit out and if it is legitimate. The extra stuff in the cable and the communications explains the licensing Apple pushes and the increased costs. It also explains why Apple would not want to go USB-C because they would lose money, data, and control over the cables.

    @webluke@webluke Жыл бұрын
    • Doesnt help when their shitty cable works with speed standards from the year 2000.

      @Henry14arsenal2007@Henry14arsenal2007 Жыл бұрын
    • They did a gotcha and limited their new iPhone 15 base models to USB Type C with USB 2.0, but with the Pro Model having Thunderbolt. Touche Apple

      @HoloScope@HoloScope Жыл бұрын
    • I'm wondering the same thing, Apple cables are the worst for durability at the stress area where the cable meets the end. Some manufacturers do a much better job on the cable build, they last a lot longer.

      @madog1@madog1 Жыл бұрын
    • They will soon

      @m7mdzuhair9gamer61@m7mdzuhair9gamer61 Жыл бұрын
    • @@HoloScope the EU hit them once AGAIN with their bullshit and said they cannot limit any of it. lol

      @Atixtasy@Atixtasy Жыл бұрын
  • I always kind of knew there was something going on. My "genuine" apple cable would only briefly show a charge symbol before the phone would no longer respond. It seems the "genuine" chip in my cable was "taught the wrong response" hehe. Brilliant video, even a simple user like me can understand, and your graphics/editing are top notch! Another sub for your stack ;)

    @1995Links@1995Links Жыл бұрын
    • this is so insane. the cables are a genuine and certified scam and people are so jolly about it

      @StarmenRock@StarmenRock3 ай бұрын
  • I love your approach to reverse engineer the protocol. Waiting for part 2 :D

    @Termynat0r@Termynat0r Жыл бұрын
  • I always get excited when I see a new stacksmashing upload! Looking forward to the rest of this series

    @_yaseen@_yaseen Жыл бұрын
    • stack smashing detected (core dumped)

      @ME0WMERE@ME0WMERE Жыл бұрын
  • Cool =D You've made excellent progress there! Looking forward to part 2 =D

    @GadgetUK164@GadgetUK164 Жыл бұрын
  • The algorithm just gave me this gem that I didn't know I needed to see. What a great video.

    @matusholek1364@matusholek1364 Жыл бұрын
  • Great explanation, thanks so much for all your hard work.

    @ty2k@ty2k Жыл бұрын
  • I need the next video! This seems like a series episode and I want to watch all the episodes. 😂 Nice video, bro. I like to brush up some bits, and this type of video is very pleasant to me.

    @JLenival@JLenival Жыл бұрын
  • “Part 1” *_dips for 7 months_*

    @Bromon655@Bromon6557 ай бұрын
  • I haven't done much research yet, but I'd be very interested in comparing the advantages and disadvantages of USB-C vs Lighting. Anyway, great video!

    @john.dough.@john.dough. Жыл бұрын
    • Advantage: more money for apple Disadvantage: literally everything else

      @makuru_dd3662@makuru_dd3662 Жыл бұрын
    • @@makuru_dd3662 Advantage; More durable than USB-C since there is no middle part to break. Advantage: Smaller than USB-C and takes up less space.

      @JamesR624@JamesR624 Жыл бұрын
    • @@JamesR624 Is it more durable? At least in my experience, USB-C has been way more durable. Lightning cables tend to short out between pins 7 and 8

      @griffin8062@griffin8062 Жыл бұрын
    • ​@@JamesR624 Lol! I have 9 year old USBC cables that still work like new. My Grandma has gone through another Apple branded lightning cable every other month since getting her polished turd of a phone.

      @operator8014@operator8014 Жыл бұрын
    • @@griffin8062 not the cable, it's the port

      @fiirasmusic5366@fiirasmusic5366 Жыл бұрын
  • Great Video. Already waiting for Part 2 :)

    @noone31337@noone31337 Жыл бұрын
  • Wow thats amazing! Looking very forward to the next part

    @1blendercraft1@1blendercraft1 Жыл бұрын
  • Being a software developer in the automation industry, i love this kind of reverse engineering videos. Looking forward to the next parts ;)

    @mika-racing@mika-racing10 ай бұрын
  • Great work! Can't wait for part 2!

    @jacobblomquist5288@jacobblomquist5288 Жыл бұрын
  • awesome man!! eagerly waiting for part 2

    @shubhambora6758@shubhambora6758 Жыл бұрын
  • fascinating. Neat how you can figure out so much from so little

    @benservey9295@benservey9295 Жыл бұрын
  • Great video! It's really interesting to learn about the technical details of Apple's Lightning connector and how it works. I appreciate the clear explanations and diagrams, and the various links provided for further exploration. Looking forward to Part 2!

    @TheXnyu@TheXnyu Жыл бұрын
    • Awesome, thank you!

      @stacksmashing@stacksmashing Жыл бұрын
  • Waiting for part 2 😋

    @Jamboreeni@Jamboreeni6 ай бұрын
  • Thank you for yet another fantastic video!

    @phire0@phire0 Жыл бұрын
  • absolutely fascinating, can't wait for more videos!

    @venjsystems@venjsystems11 ай бұрын
  • Looking forward to part two!

    @tosch9057@tosch9057 Жыл бұрын
  • Having a knowledge like yours just seems like rocket science. Just awesome

    @ranjanadissanayaka5390@ranjanadissanayaka5390 Жыл бұрын
  • My mind is blown. This video (these videos) are awesome. Thank you so much for sharing your knowledge.

    @anthonya824@anthonya82411 ай бұрын
  • Congrats to the 150k subcribers! and realy nice video !

    @Marvinzock34@Marvinzock34 Жыл бұрын
  • very nice I love the breakout header you made.

    @yaghiyahbrenner8902@yaghiyahbrenner8902 Жыл бұрын
  • This is really cool! Also, side note, would you do this same analysis on one the old 30 pin cables? It would be really cool to see the differences between the older technology and the newer!

    @TheTotallyRandomGuy@TheTotallyRandomGuy11 ай бұрын
  • Please continue! Your work is great!!! When is the second part coming?

    @miwer2010@miwer20107 ай бұрын
  • WOW!!!! This is such a unique video! Never seen something like this before in my feed.

    @Muhammed.Yaseen@Muhammed.Yaseen11 ай бұрын
  • Amazing video, waiting for part 2!

    @zoltanujszaszi@zoltanujszaszi Жыл бұрын
  • Awesome detailed video now I want to see Type c power delivery and other protocols as well from you.

    @AKG58Z@AKG58Z Жыл бұрын
  • Woah this is amazing. I just came from watching Exploring The simulations video on adding USBC to airpods. This is amazing to see

    @matrixmodexp@matrixmodexp Жыл бұрын
  • Great explanation and neat graphics!

    @saschakaupp@saschakaupp Жыл бұрын
  • Hey, I love this video, cant wait till part 2

    @ShiroKlein@ShiroKlein Жыл бұрын
  • amazing video, cant wait part for other parts

    @kagandemirarslan872@kagandemirarslan872 Жыл бұрын
  • Waiting for pt.2 for 6 months now

    @seanho123@seanho1239 ай бұрын
  • Where’s part 2? :(

    @DanDan-zs6wg@DanDan-zs6wg Жыл бұрын
  • Great video - lots of information and well paced. I'm looking forward to part 2!

    @compu85@compu85 Жыл бұрын
    • Thank you!

      @stacksmashing@stacksmashing Жыл бұрын
  • part 2 when :(

    @hellopsp180@hellopsp1803 ай бұрын
  • Hey, awesome video, loved all the technical details! On a side note, what kind of logic analyser would you recommend for someone just getting into hardware security? The Salae ones you showed are a little outside my undergrad budget ;) Will an ESP32/Raspberry Pi Pico suffice for most beginner usecases? What if I'm dealing with negative voltage signals? Many thanks for your videos! Got here after LiveOverflow recommended them :)

    @aathish04@aathish04 Жыл бұрын
    • You can get some very cheap ones on Amazon (like $10) - I think those are great in the beginning (and I still often use them)

      @stacksmashing@stacksmashing Жыл бұрын
    • @@stacksmashing alright, I'll have a look at those. Thank you so much!

      @aathish04@aathish04 Жыл бұрын
    • @@aathish04 I've used micros in the past, they're nice but one bit me when it pulled my i2c lines low when it wasn't powered. I use a digital discovery at work and it's amazing, especially with its high speed adapter kit. Very clean signals.

      @Neywiny@Neywiny Жыл бұрын
    • Personally I bought a 70$ one on Amazon and it does more than enough for me. Have used it a good bit. Probably the 10$ one would be enough for most to be honest

      @newmonengineering@newmonengineering Жыл бұрын
  • Having worked on embedded projects that communicate with iOS devices before, I'm very interested to see where this goes. Some of this I recall from the spec; other parts it seems they don't even share with their MFi partners. I will not be sharing more information, as I don't even remember what I can and can't legally say.

    @duncanw9901@duncanw9901 Жыл бұрын
    • MFi NDA

      @kwamenaplays5899@kwamenaplays5899 Жыл бұрын
    • They were doing funky stuff with the 30 pin cable back in the day as well. A mix between analog and digital. I may be recalling this incorrectly, but I believe you had to do some dance applying different resistances to different pins in a specific order as part of the handshake. Really finicky stuff to get right. Different devices would react slightly differently to that handshake, to the point where even the different storage options of the same model of iPhone/iPod had an effect. You really had to test every permutation many times (50+) to be sure it worked. But take the details with a large grain of salt, I just did the testing. I remember this from hearing the engineers complain about it back then. I could be wildly wrong on the handshake part. I'm not worried about an NDA because I never signed anything like that with Apple. And the company where I got experience with this went bust a long time ago. Plus I don't think they really care about the 30 pin connector anymore, as long as you're not going around putting it on commercial products...

      @Niosus@Niosus Жыл бұрын
    • True. Like your exp, even in future, even for USB they are circumventing the standard protocol. USB already has data, power, fast charge etc. as standard - Apple is using only basic power from standard set, and they are using proprietary specs for other things (usb 3.1+ data speed, fast charge etc). All in the pretence of customer safety :)

      @rahuls4863@rahuls4863 Жыл бұрын
    • @@rahuls4863 as louis rossman quotes, "safety and security!"

      @KiwisCassie@KiwisCassie Жыл бұрын
    • @@rahuls4863 I have a feeling the EU will strike them down for that.. or at least try and say "you know what we meant, we're not tolerating *malicious* compliance, do it like everyone else does"

      @teknikal_domain@teknikal_domain Жыл бұрын
  • Take this subscription, you deserve it. Quality content.

    @desidark1243@desidark124311 ай бұрын
  • Wow. Heavy nice work Bro. Thanks 🙏 4 content

    @feierpack@feierpack Жыл бұрын
  • This was such a dope video when part 2 gonna drop it’s been 4 months

    @nooranshdhaka@nooranshdhaka11 ай бұрын
  • I wonder, would this be able to debug an issue on a dumpster iPhone I found recently? I failed to flash iOS onto it, no matter if recovery or DFU mode, it always errors out or reboots at some point unexpectedly, and I have no idea what's wrong with it. I suspect a broken flash chip, but I can't tell for sure.

    @EpicLPer@EpicLPer Жыл бұрын
    • I doubt it to be honest :)

      @stacksmashing@stacksmashing Жыл бұрын
    • Send it to me. One of my iPhone's rudely erased all data on me after changing passcode. 2 failed attempts and I freaked out shut off the phone (despite the glitch yes the GLITCH) I rebooted the iPhone thinking it'll solve the glitch but I did not know what I just done and bam first passcode attempt and it is erased everything. (It may have been poor wifi during request passcode change so from now on anytime I change it I make sure wifi is flawless beforehand!) Anyways the point: this erased iPhone can still jailbreak using i2c box and even shows the iOS version 13.6.0 I am blaming Apple here. If it did erase "all data" then why the heck is it able to do this? P.S. This type stuff makes me want to sue company. False advertising IMO.

      @michealfunickrr3717@michealfunickrr3717 Жыл бұрын
  • Really love your videos. Waiting for Part 2! :-)

    @bjoerrrrn2005@bjoerrrrn2005 Жыл бұрын
  • Omg you are explaining it very very well done 👏🏾

    @Amyunus@Amyunus Жыл бұрын
  • "in the next video?" what!? fastest 9 mins ever. what an awesome video.

    @Moker49@Moker49 Жыл бұрын
    • Thank you! :)

      @stacksmashing@stacksmashing Жыл бұрын
  • I am subscribing immediately because this is mind blowing! 🎉

    @bravonorthyt@bravonorthyt Жыл бұрын
  • would love a second part if you have time :D

    @suncrafterspielt9479@suncrafterspielt9479 Жыл бұрын
  • Awesome thanks for explaining in depth.

    @AshishEmbedd@AshishEmbedd Жыл бұрын
  • this is so interesting wow! im now very curious about a few things tho. 1- How do splitters work? for example i have a very cheap aliexpress splitter that basically lets me plug in both charging cable and lightning earpods on my iphone at once, im guessing this thing is 100% passive but i have no ide and im not about to destroy it rn tbh. but if its passibe how can it communicate with both things at once? and if active, how does it get to split these two things? 2- does the cable reply to the device which charging capabilities it has? like if it can do fast charging or not, or is that linked to the modle number or name itself? 3- does the cable also talk to the charger it connects to? like does the apple PSU get any information about the lightning cable or device? apart from power delivery on fast chargers that is, especially curious on the old usb-a 5w and 10w ones and 4- how do fake cables work then? ive had bad luck getting some knockoff ones bc they would charge very very slowly and im thinking if it might be bc the controller was answering stuff wrong and the iphone has some sort of anti-illegitimate mehcanism or something or if it just replied as if it was the slowest charging cable that exists, i really hope youll check this stuff at some point plz! btw for reference this is the splitter i have (different store same thing tbh, not great bc it requires regular cleaning for it to work, also if u dont have experienc with aliexpress choose the aliexpress saver shipping unless its wayy too expensive for u bc at least in spain that option takes 2 weeks but the caniao expedited economy aka tghe default one for this takes months) www.aliexpress.com/item/1005004576959652.html

    @DEMENTO01@DEMENTO01 Жыл бұрын
  • Wow. As an Apple employee at a Genius Bar, this video brought me a lot. As I love giving my customers some details about their products, this is a lot! Until now, just said that their cable is not only a cable. Now I can explain that there’s a real chip with which the iPhone is talking to. In an other way, can’t understand why we have not tools to determine if a cable is genuine or not.

    @DamienBOURSAUX@DamienBOURSAUX2 ай бұрын
  • Respect man. You are truly awesome

    @mprebbz@mprebbz Жыл бұрын
  • You are super good at reverse engineering. Extremely straight forward and informative.

    @nicknorthcutt7680@nicknorthcutt76803 ай бұрын
  • Awesome video. Loved every bit of it (pun intended).

    @matoatlantis@matoatlantis Жыл бұрын
  • Can't wait to see the next video!!!

    @Scyth3934@Scyth3934 Жыл бұрын
  • im sold, new sub over here, im waiting for part 2

    @rouuuk@rouuuk Жыл бұрын
  • This outdoes the video I uploaded about Lightning cables, lol. Excellent job! Very informative!

    @rebootretro@rebootretro Жыл бұрын
    • Oh do you have a link to that? Do you mean this one? kzhead.info/sun/n9OPeriEjKx3YKM/bejne.html Nice channel :)

      @stacksmashing@stacksmashing Жыл бұрын
    • @@stacksmashing Thank you! Although I still somewhat envy your technical abilities, haha. I've worked with electronics for a very long time, but I wish I was more proficient with logic analyzers, scopes, etc. I've seen your videos before, particularly the AirTag one. Excellent stuff!

      @rebootretro@rebootretro Жыл бұрын
  • This dude is pretty cool 👌 you have earned a well deserved sub 😁

    @dogedog2447@dogedog24473 ай бұрын
  • This was honestly really interesting to watch

    @zUltraXO@zUltraXO Жыл бұрын
    • Thank you! :)

      @stacksmashing@stacksmashing Жыл бұрын
  • This is great part 2 can’t wait … there are some interesting other projects that might be able to be integrated with that tamarin cable, not very sure what “level” of signal processor / logic analyzer is required. But I have seen some open source logic analyzer on hackaday that use the PIO cores to get up to 24 channels , 16, 8… pretty sure you could pipe the GPIO that’s handling that communication into the other cores and have the ARM cores act like a TCP server to send the data through the USB connected to the PC to double as tamarin / logic analyzer . Very cool project hope there is part 2 , and maybe some Lightning peripherals? Like lightning to usb hdmi hubs ? Get the readings from those ?

    @seanperez1210@seanperez12105 ай бұрын
  • Amazing video. Please keep it going!

    @EdwardMordrake618@EdwardMordrake618 Жыл бұрын
  • you remind me of Ben Eater, not comparing efforts here, great video. subbed.

    @parimalarenga92@parimalarenga92 Жыл бұрын
  • Guess I have to subscribe to stay tuned!! Also what analyzer do you use?!?!

    @JRis44@JRis44 Жыл бұрын
  • thank you!! can wait what next!!!

    @bnk28zfp@bnk28zfp Жыл бұрын
  • What a madman, this video was AWESOME!

    @stonedhackerman@stonedhackerman Жыл бұрын
  • Fascinating! Thank you.

    @danrichman1@danrichman1Ай бұрын
  • Great to see you back on the scene. Superb content delivery. Are you planning on working on a possible jailbreak?

    @kritikusi-666@kritikusi-666 Жыл бұрын
  • fun fact, iPad Pro gen 1 and 2 use all 16 pins on lightning for usb 3.0 speeds (in conjunction with a usb-c to lightning cable)

    @johnadams6249@johnadams6249 Жыл бұрын
    • Interesting, I didn’t know! Thanks :)

      @stacksmashing@stacksmashing Жыл бұрын
  • Been waiting for pt.2 for two months now

    @seanho123@seanho123 Жыл бұрын
  • This video got me all charged up. Positively electrifying.

    @frequencymanipulator@frequencymanipulator Жыл бұрын
  • This is interesting. Thanks for sharing.

    @asminsilwal5518@asminsilwal5518 Жыл бұрын
  • you are a gem!!! thank you for this video.

    @ttxb@ttxb Жыл бұрын
  • This is so incredibly awesome

    @pallzoltan@pallzoltan Жыл бұрын
  • Eagerly waiting for part 2!

    @ra1nmaker001@ra1nmaker001 Жыл бұрын
  • This is excellent!

    @Schimnesthai@Schimnesthai Жыл бұрын
  • Wow, nice one. For how long did this channel exist? Subscribed.

    @garydunken7934@garydunken7934 Жыл бұрын
  • Thank you for your very detailed technical sharing, why can't I find the second part, thank you.

    @BD7PA@BD7PA10 ай бұрын
  • Perfect timing, just before they are forced to use USB-C :D

    @altayakkus4611@altayakkus4611 Жыл бұрын
    • let's hope they dont manage to get around it

      @-aexc-@-aexc- Жыл бұрын
    • @@-aexc- I think that they announced that they are going to follow it.

      @altayakkus4611@altayakkus4611 Жыл бұрын
    • @@altayakkus4611 They have confirmed they will follow the law. The law mandates USB-C for charging. USB-C connectors are already a clusterfuck used for many different standards, and rumors are already that the USB-C cables Apple plan on the next iPhone will need Apple certification for full functionality.

      @klafbang@klafbang Жыл бұрын
    • @@-aexc-Everyone should have been forced to use USB Micro.

      @jonasthemovie@jonasthemovie9 ай бұрын
  • Keep up the good work

    @MxGiK3HuNNx@MxGiK3HuNNx Жыл бұрын
  • I have no interest in this space but LOVED this vid because it as so clear and well produced.

    @1fattyfatman@1fattyfatman2 ай бұрын
  • Really really interesting.... Dumb question/idea.... Would it be possible via rpi0 or RPI pico to convert video signal from lightning to uvc USB gadget mode?

    @hkfuertes@hkfuertes Жыл бұрын
  • Wonderful video. Thank you!

    @benhernandez9571@benhernandez9571 Жыл бұрын
  • Love the content 👍

    @l3yce583@l3yce583 Жыл бұрын
  • Good used analyser experience !

    @serggorod1423@serggorod1423 Жыл бұрын
  • Thanks for your sharing

    @allezvenga7617@allezvenga7617 Жыл бұрын
  • Didn’t understand a single word, but hey man, nice video, enjoyed it 😄

    @schmidvid@schmidvid Жыл бұрын
  • Wow you are a great communicator!

    @itemushmush@itemushmush Жыл бұрын
    • Thank you, appreciate that :)

      @stacksmashing@stacksmashing Жыл бұрын
  • I want the next video this is so cool!

    @Fewnity@Fewnity Жыл бұрын
  • Before watching the video, I thought that embedding the chip in the USB cable was stupid, because it costs more and creates more waste. Now, I'm waiting for the next part.

    @alexnoha@alexnoha Жыл бұрын
  • Wow, very great explanation. I was wondering if it's the same thing with the PMICs shorting out on the 6 and 6s+, does it explain the PMIC shorting when plugged with a non-genuine cable? Or is it just coincidence ?

    @ahmedtwahir@ahmedtwahir Жыл бұрын
  • This is awesome

    @zachsents@zachsents2 ай бұрын
  • Algorithm sent me here, and I’m glad! Can’t wait for the rest!

    @Nathan123Bhi8@Nathan123Bhi8 Жыл бұрын
  • I wish you would do longer videos instead of these 10-minute parts, thanks for the content though, keep it up. Looking forward to making my own cable.

    @nullptr.@nullptr. Жыл бұрын
    • I know what you mean - it’s pretty intense to produce though :) I might try some longer content Thanks for the feedback!

      @stacksmashing@stacksmashing Жыл бұрын
    • 10 minutes is ok in my opinion

      @Scyth3934@Scyth3934 Жыл бұрын
  • Awesome video

    @rafaelcoelho5226@rafaelcoelho5226 Жыл бұрын
  • You should try teaching profession! Your simplicity in presentation and effective communication makes it easy to understand and learn.

    @Ganesh_Sh@Ganesh_Sh Жыл бұрын
KZhead