Binary Exploitation Deep Dive: Return to LIBC (with Matt)

Поделиться
HTML-код
  • Опубликовано: 7 июн 2021
  • If you would like to support the channel and I, check out Kite! Kite is a coding assistant that helps you code faster, on any IDE offer smart completions and documentation. www.kite.com/get-kite/?... (disclaimer, affiliate link)
    For more content, subscribe on Twitch! / johnhammond010
    If you would like to support me, please like, comment & subscribe, and check me out on Patreon: / johnhammond010
    PayPal: paypal.me/johnhammond010
    E-mail: johnhammond010@gmail.com
    Discord: johnhammond.org/discord
    Twitter: / _johnhammond
    GitHub: github.com/JohnHammond

Комментарии • 193

  • @robertwouda
    @robertwouda 3 года назад +31

    Ngl that was 2 hours and 12 minutes well spend. Very interesting and cool

  • @praetorprime
    @praetorprime 3 года назад +26

    My C/ASM is rusty, but Matt is doing a great job at refreshing my memory as you go along. John, too, is an intuitive pair-programmer. I've always wanted to know how to turn a "buffer overflow" vulnerability into an exploit, mostly out of frustration at hearing so much about them in college but never actually being shown how one works. Such a great video!

  • @aarondinesh3657
    @aarondinesh3657 3 года назад +104

    I would love to see you and Matt do more colabs in the future!

    • @Hyuntube996
      @Hyuntube996 3 года назад +1

      Yeah man 🙃

    • @charlesmctavish5188
      @charlesmctavish5188 2 года назад

      Yeah very knowledgeable and has clear explanations. Great teacher

  • @joeymelo2882
    @joeymelo2882 2 года назад +1

    What an incredible video. I've been meaning to watch for this for days and finally set up a time for that. Everything in detail, amazing. Thanks for the content.

  • @apjohnite1302
    @apjohnite1302 3 года назад +47

    Great watch for anyone who is new to ret2lib. On getting the address of /bin/sh string (1:07:46) Loading the libc.so.6 into Ghidra will work, but it was imported with a base address of 0x100000, which John didn’t subtract from the address of the string, (a mistake he attributes to a typo later). An easier approach would be to use strings -tx libc.so.6 | grep /bin/sh

    • @CMorlandBassist
      @CMorlandBassist 3 года назад +4

      Thanks for explaining this. I also noticed it wasn't a typo, but wasn't sure how ghidra could say it's address started at 0x2B when it was really 0x1B. Do you know why it had a base address of 0x100000?

    • @apjohnite1302
      @apjohnite1302 3 года назад +1

      @@CMorlandBassist No idea, but it usually defaults to that for an executable with PIE set. There is an option to override the base address when you import.

    • @jmiguelhernandez1640
      @jmiguelhernandez1640 Год назад

      thanks, i was wondering if string had an option for that.
      i found the memory map window in ghidra not only makes clear what base is used but it lets modify it as well.

  • @AbandonRule
    @AbandonRule Год назад

    I was watching this on the TV so I really appreciate that you strive to make sure everything was large enough. Thank you! Amazing video. Want to see more with Matt!!

  • @Raxnub
    @Raxnub 2 года назад +2

    Loved this John, definitely consider doing more of these please. I kept up with what was going on probably up until about 1hr 25 mins. I can feel a rewatch coming on!

  • @potatoonastick2239
    @potatoonastick2239 3 года назад +20

    Yes please do more of this! Amazing learning content, even more so than usual IMO. Great stuff!

  • @GameOnBeast
    @GameOnBeast 2 года назад +3

    It's been ages since I last subscribed to someone. But if you make a video this awesome, it can't be help.
    Thanks for making this you guys! Would love to see more

  • @snakebarber
    @snakebarber 2 года назад +1

    Thanks for this! I still can't do what was shown on my own, but I'm about 4 steps closer than before I watched it. Learned a ton.

  • @maxpowell3528
    @maxpowell3528 2 года назад

    This was absolutely great, thanks John and Matt !

  • @PaulzePirate
    @PaulzePirate 3 года назад +3

    Amazing content, really hope there is more like this. Would also love to see some of the more advanced stuff. As Matt said, it's very difficult to find unless you are paying for it.

  • @DickSvensson
    @DickSvensson 3 года назад

    Awesome aspect of the videos, like the format and the dialog!

  • @george___43
    @george___43 3 года назад +2

    These guys are awesome, surprisingly I understand every step!!! Great video.

  • @jmprcunha
    @jmprcunha 3 года назад

    I always learn or recall something. I'm "hooked" on Your videos! Thank You for sharing!

  • @n00b-hax0r9
    @n00b-hax0r9 3 года назад

    There was a lot in this one. Will have to come back to this multiple times. Thanks a lot for this!

  • @Bearded_1
    @Bearded_1 3 года назад

    Amazing video! I learned a ton. Please, please, please make more of these!!!

  • @Meow-meow421
    @Meow-meow421 Год назад

    You're the gold mine fr thank you so much for the content we all appreciate your hard work❤❤🎉😊

  • @jmiguelhernandez1640
    @jmiguelhernandez1640 Год назад +17

    in case anyone is wondering, the offset error for "/bin/sh" string wasn't a typo. When it was taken from ghidra, ghidra loaded the lib with a base address of 0x100000 so it was off by that much. 0x2B40FA-0x100000 = 0x1B40FA

  • @claymoody
    @claymoody 3 года назад

    Great video, Matt and John. Thanks for putting that together. Go Tigers!

  • @trucotrecaxbox2904
    @trucotrecaxbox2904 3 года назад +1

    Really good video to start. I really wanna more of this videos, better with Matt, he explains really good.I am gonna re-see a lot of times, get notes and search throught internet all of this.

  • @chriskaprys
    @chriskaprys 2 месяца назад

    Lads: this. was. AWESOME!
    Matt's a natural-born, superb teacher; John you asked great questions and dropped in very useful clarity points and made me feel like I was Matt's student sitting right there as this lesson developed. 2 hours absolutely flew by and I have so much more nuts&bolts knowledge thanks to you two. 👏

  • @vibhavtiwari7260
    @vibhavtiwari7260 3 года назад

    yes sir more video like this and you just do a fab work again! thanks is all i just got for you sir. Thank You !!!.

  • @jkobain
    @jkobain 3 года назад

    Setting up the tools may often become the most interesting part of the event.
    Whatever, I'm ten minutes in, and I'm so excited!

  • @TheBrutaline
    @TheBrutaline 3 года назад

    I found my video for the weekend. Thanks John.

  • @mikewajda9912
    @mikewajda9912 3 года назад +4

    This was amazing and so informative! Please do more binary exploitation videos with Matt

  • @user-jm8kd2kr9l
    @user-jm8kd2kr9l 3 года назад +2

    You helped me through my night shift at McD, never enjoyed them more! (:❤️

  • @saketsrv9068
    @saketsrv9068 2 года назад

    Thanks to both of you legends

  • @ernestoo8313
    @ernestoo8313 Год назад

    So good! Thanks very much!

  • @markgentry8675
    @markgentry8675 3 года назад +9

    This was gold. Its always so useful seeing mistakes and debugging. I still don't understand everything that was discussed, esp stack alignment, but i know more than i did when i started watching. thanks guys! Oh one thing. Who is Matt? would be good to get a link to any content he has :)

  • @zeroows
    @zeroows 2 года назад

    Thank you guys. That was great.

  • @shadymorra9939
    @shadymorra9939 3 года назад

    Yes! more of this please John!

  • @davidcopenhaver5583
    @davidcopenhaver5583 3 года назад

    Really great! A+ I would definitely watch more like this

  • @Venom-ne4ox
    @Venom-ne4ox Год назад

    Great video. So much foundational stuff, please bring this guy back!

  • @omarjarkas2175
    @omarjarkas2175 3 года назад

    Very educational, amazing video!!

  • @nicooolai
    @nicooolai 3 года назад +1

    This was an incredible video.
    VERY educational. More of these, please :)
    Now I want to be Matt when I grow up..

    • @marcovalentinoalvarado3290
      @marcovalentinoalvarado3290 3 года назад +1

      Also I recommend you another hacker with a youtube channel called "Kindred Security" he teaches as well how to bypass security measures for binary exploitation

  • @orgozlan323
    @orgozlan323 3 года назад

    Thank you matt and john!!!

  • @maxmusterspace6037
    @maxmusterspace6037 Год назад

    That was the best tutorial on rop and ret2libc I have ever seen. By far!

  • @AshokKumar-bu2gk
    @AshokKumar-bu2gk 3 года назад

    Awesome work guys !!

  • @utkarshrai9727
    @utkarshrai9727 Год назад

    How did I miss this goldmine of a video before? Got here from the new vid of Binary Exploits :3

  • @kuperrr6776
    @kuperrr6776 2 года назад

    I honestly didn't understand a shit but I loved the amount of structural content I learned, and how the channel works in general, thanks for the information! Im learning a lot :D

  • @alvinkhamron7430
    @alvinkhamron7430 3 года назад

    Greate video John very big fan hope to see more videos like this soon.

  • @Handskemager
    @Handskemager 2 года назад

    Such a morale boost to see better people than me screws up and have to hunt down bugs, great video ! :)

  • @nekkrokvlt
    @nekkrokvlt 10 месяцев назад

    Awesome video guys !

  • @SRGamingYT
    @SRGamingYT 2 года назад

    you have to keep going with this, AMAZING video learned so much and i solved this ctf by my own yesterday tho lol.. STILL learned a lot !!

  • @znation4434
    @znation4434 3 года назад

    Very interesting, please do more!

  • @HAGSLAB
    @HAGSLAB 3 года назад

    This is a gem John!

  • @inhhaile7495
    @inhhaile7495 3 года назад

    This saved my day, and could be a few more days reading into more confusions

  • @ienze
    @ienze 2 года назад

    I am actually grateful that you didn't capture audio at the beginning because the setup of tools isn't so important and we could still enjoy it in a sped up version.

  • @gsfare1
    @gsfare1 3 года назад +1

    That was awesome! I learned a lot, thank you. Very helpful how you went through the full debugging process and also prompted some really great questions. Nice work.

  • @maheepim
    @maheepim 3 года назад

    Had been waiting for this

  • @christopherboisvert6902
    @christopherboisvert6902 3 года назад +2

    Matt is one of the most brilliant person I have ever heard in computer science field yet x)

  • @lennyaltamura2009
    @lennyaltamura2009 Год назад

    Thank you for sharing.

  • @rbxdev4626
    @rbxdev4626 3 года назад +1

    Hey John rbx here, glad you are taking the journey with binary exploitation quick tip for finding that "/bin/sh" address using strings itself
    strings -a -t x path2libc | grep "/bin/sh"

  • @jcs0984
    @jcs0984 Год назад

    Holy crap that was a ride for a noob like me. Thanks so much!

  • @compscilaw
    @compscilaw 23 дня назад

    I prefer the weird commentary. So much more. I love the idea of playing the coding as fast as we can see it while commenting over it. Such a better way to digest the information.

  • @WhatTheWeb
    @WhatTheWeb 3 года назад +2

    Awesome video as always. Just wanted to note that the /bin/sh address bug came from the fact that you copied the address offset from ghidra which, by default, will not load in binaries with a default base address of 0x00000000. You didn't typo! :p

  • @cXedis
    @cXedis Год назад +7

    13 months later, still amazing. It's funny that when this released none of it made sense to me but it's been a crazy year. Matt and John thanks for taking the time to explain in such awesome detail.

    • @biblemansings
      @biblemansings Год назад

      Did you learn at school?

    • @biblemansings
      @biblemansings Год назад +1

      I’m just starting my Cyber Security courses

    • @cXedis
      @cXedis Год назад +1

      @@biblemansings not exactly? 20 years in IT, also BHIS has "Pay What You Can" classes you take for free. I have no formal edjumication in the field beyond those classes. I make my way by googlfu and a head that's sturdy enough to eventually break thru most walls...eventually.

    • @andresjoelrodgers
      @andresjoelrodgers Год назад

      @@biblemansings ❤

    • @andresjoelrodgers
      @andresjoelrodgers Год назад

      🎉

  • @mossdem
    @mossdem 3 года назад +5

    This guys really good at breaking stuff down! It was still a little advanced for me but still really enjoyed it

  • @Thiago1337
    @Thiago1337 3 года назад

    Yes, more of these!

  • @Bromon655
    @Bromon655 3 месяца назад

    That first 10 minutes had my head spinning 😵‍💫 I got completely lost

  • @pwndumb2903
    @pwndumb2903 3 года назад

    Amazing explanation !!!

  • @walidantaki3026
    @walidantaki3026 2 года назад

    wow amazing content learned a lot

  • @aaaron19
    @aaaron19 3 года назад +1

    Awesome video!! Please do more RE

  • @PatrickHener
    @PatrickHener 3 года назад

    This was hell of a good video. Do that again with a more complex binary exploitation!

  • @entheo_christ2223
    @entheo_christ2223 2 года назад

    John Hammond is one of the most likeable people on the internet. Great work man.

  • @points7824
    @points7824 3 года назад

    ret2libc ctfs is where i struggle so thank you so much for this. I will be using this for practise so i would be so happy if you could catogorize the video so i could jump places that would be AWESOME

  • @samyepthatsme
    @samyepthatsme 3 года назад

    This is such a cool video! Could you just make a video tutorial on every section of the ShellCoder’s Handbook? 😂

  • @coffeedata7107
    @coffeedata7107 3 года назад

    This is gold mate

  • @ahmedmani1051
    @ahmedmani1051 3 года назад +4

    please when you do one of this videos make both persons voice equal i had to keep my hand on the volumes key entire time and add subtitles other than that thank you so much

  • @overflow_and_programming5215
    @overflow_and_programming5215 3 года назад

    Thank you bro

  • @genezisdj
    @genezisdj 3 года назад

    i really liking you stoff btw so i can learn more

  • @seanvinsick5271
    @seanvinsick5271 3 года назад +1

    I loved this. Btw readelf -W won't truncate the symbol names.

  • @Majkieboy
    @Majkieboy 3 года назад

    Super hype!

  • @toastom
    @toastom 2 года назад +2

    Super interested in binary exploitation and the lower-level hacking that's more closely related to hardware elements of hacking. I'm happy this exists.

  • @Johnstuart2023
    @Johnstuart2023 2 года назад

    thanks bro

  • @oneloveafrica8860
    @oneloveafrica8860 4 месяца назад +1

    he knows everything about that he's smart on revers engineering I like it wooow

  • @kartibok001
    @kartibok001 3 года назад +1

    Really enjoyed the video and picked up some good notes, however if that was "basic", I think I need to search for the "ba" lessons :)

  • @yoshi5113
    @yoshi5113 3 года назад +26

    For beginners that seem expert for me.. 😅

    • @robinhood3841
      @robinhood3841 3 года назад +9

      Well binary exploitation is a bit advanced topic, you should at least have a basic on assembly so you can do some reversing on the binary , and know about stack and registers and how the variables and arguments laid in the stack and how pop and push operations works how the calling convention works in x86 and x64, what are the memory segments and what are the protection mechanisms of the memory, the techniques for bypassing those mechanism etc once you figure that out it won't look that hard, and remember practice is the key the more you practice the better you become

    • @cedricvillani8502
      @cedricvillani8502 Год назад

      There’s been enough binary exploiting this year

    • @khaledmohamed-ee6hf
      @khaledmohamed-ee6hf Год назад

      ​@@robinhood3841 can you suggest a book to start reading

    • @josephalan31
      @josephalan31 Год назад

      @@khaledmohamed-ee6hf look into opensecurity2 1001 then do 2001 then look into pentester academy 86 x64 brother

    • @josephalan31
      @josephalan31 Год назад

      All of them freely available on RUclips

  • @greob
    @greob 3 года назад +1

    That was very insightful and interesting. Too bad the sound levels were very uneven. Still, thanks for sharing!

  • @REktSigMa
    @REktSigMa 3 месяца назад

    1:48:37 its the "relative path vs absolute path. this is that move back path. Sort a like when your properly referencing folders in your program, like a header file.

  • @ReubenSammut
    @ReubenSammut 3 года назад +1

    Well done John and Matt. Although I've been doing these for a while, I still managed to learn new things. For next time, try to add one gadgets ;)

  • @aizen310
    @aizen310 2 года назад

    thanks fot your hard work! this videos are gold! just hope to technology used for the good of humanity...

  • @cuishencheng
    @cuishencheng 6 месяцев назад

    Really really cool

  • @johnsonkxks5835
    @johnsonkxks5835 2 года назад

    congrats on 420k

  • @tvathome562
    @tvathome562 2 года назад

    Wow this was fun, reminds me of stepping through softIce in 1990's to crack hobbled programs, sitting down with reems of printer print out and a pen, working through by hand. Oh things were so much simpler back then.. And ida pro was freeware.. The only Advantage now is you don't have to go to library or wait an eternity to download a program

  • @user-my5cu7oy5i
    @user-my5cu7oy5i 2 года назад

    Friday night in lockdown…. COVID is getting me into hacking. Your videos are amazing!

  • @dontdishfish5861
    @dontdishfish5861 2 года назад

    Great video! You and Matt make a great pair of teachers.
    I wanted to join your discord server but I don't think the link is working. The rest of your website works though :)

  • @zeuserrikkian4475
    @zeuserrikkian4475 2 года назад

    Wow. Mindblown

  • @AFchump78
    @AFchump78 3 года назад +1

    Morning all.

  • @AFchump78
    @AFchump78 3 года назад

    Any good reading material on the why I need to use pop_rdi and specifics? Replicating the success of this but Im kind of wondering about the why. Only have done shell code ones on windows(ecppt).

  • @MrGuardianX
    @MrGuardianX 3 года назад

    Very cool video thank you! Although if you don’t mind, could you please edit the audio a little. You were really load while the speaker is almost indistinguishable. So when he talks I increase my volume, but then your comment comes in and my ears start bleeding. Otherwise very cool content!!

  • @TracerPortable
    @TracerPortable 3 года назад

    That was great but I feel like Matt was too quiet compared to you, and when I heard you loud and clear sometimes I had problems with Matt. But overall love the vid. I feel like I'm going to return to it frequently

  • @00eunderscore70
    @00eunderscore70 Год назад

    Hi John, im just getting into Binary Exploitation and I would like to ask about the terminologies and how they work. For now what does the off-set do? I have seen it beeing used multiple times in different avenues of the video. Awesome educational video! Cheers

  • @gstud210
    @gstud210 3 года назад

    Do more videos with him!!

  • @everybot-it
    @everybot-it Год назад

    I've just watched through an entire video where I understood most of the terminology, but almost none of what's actually going on. Complete repeat experience of 7-8 ys ago when I was watching HTML / CSS tutorials.... so let's not get too depressed here.... :D
    Immersion -> patterns -> copy-pasting -> failing -> following expert discussions way above my level -> another course on fundamentals -> suddenly things are familiar....

  • @kiiikoooPT
    @kiiikoooPT Год назад

    does Matt also have a channel? I would love to check his channel to if he does youtube videos ;)
    this is gold for someone who just has basic knowladge and is trying to learn more :)

  • @wandersmut6326
    @wandersmut6326 Год назад

    How has a genius like this gone his entire career without anyone around him having the heart to tell him how to pronounce 'canary' or the origin of the metaphor?

  • @miinyoo
    @miinyoo Год назад

    I watch Hammond because it's a world I find entertaining if rather incomprehensible most of the time, but through osmosis I can follow along.
    This. I have absolutely no idea what's going on. This is so far in a different universe, the only reference point I understand is Memory Address. Everything else is greek.

  • @0x2a1A4
    @0x2a1A4 2 года назад

    gold!