Python & MITMProxy: Web Scraping Secret iOS App Data

Sdílet
Vložit
  • čas přidán 27. 10. 2020
  • Using Python we build a simple Goodreads webscraper using
    - MITMProxy to observe the web traffic and get the API calls
    - Requests to perform the API call in Python
    - BeautifulSoup to convert the XML data
    - Pandas to take the converted XML data and create a CSV file
    Today's question came from a stranger on the internet over at Reddit - / trying_to_make_a_simpl...
    Thank you for watching!

Komentáře • 67

  • @tracingisdrawing
    @tracingisdrawing Před 3 lety +2

    Just wanted to say thanks for these videos! I've only been learning Python for a week now, but you do well enough job of explaining your process that I can still follow along on concepts I haven't even gotten to yet. It definitely helps with getting me primed for the things ahead. Much appreciated!

  • @thewilltejeda
    @thewilltejeda Před 3 lety

    Haven't seen you post in a while , but wanted to thank you for the vids you made. They really helped get more practical uses of scraping skills

  • @the-web-scraping-guy
    @the-web-scraping-guy Před rokem +4

    Great tutorial. Love that you keep your mistakes and errors there. Very helpful

  • @Zancb
    @Zancb Před 3 lety +1

    Great video! I found you off of Reddit today. Love your production!

  • @Sodiumcola
    @Sodiumcola Před 3 lety +2

    Welcome Back, I missed these videos!!! Keep it up. Thank you

  • @nevetsspence7740
    @nevetsspence7740 Před 2 lety

    Excellent videos!! Your content helped me solve a problem I’ve had for ages!
    Looking forward to more content! Great work!

  • @YatriTrivedi
    @YatriTrivedi Před 3 lety +2

    Great series, glad you're back! I'd love a more in depth video on mitmproxy! I'm looking to start using* home assistant and I'd love a way to interact with my smart home devices and automate them in ways they won't allow me to out of the box.

  • @thewilltejeda
    @thewilltejeda Před 3 lety +8

    I was pretty psyched when this popped on my feed
    That mitmproxy thing is awesome !
    Looking forward to seeing more of your usage of mitm and what other tricks you've picked up since your last videos

    • @MakeDataUseful
      @MakeDataUseful  Před 3 lety +3

      Thanks Will, yeah MITMProxy is REALLY cool! I can't wait to share more app API fun.

  • @SOFRADAKAOS
    @SOFRADAKAOS Před 2 lety

    thanks for tutorial man this was insane. Best programming teaching technique i have ever seen.

  • @chiragdeshmukh325
    @chiragdeshmukh325 Před 3 lety

    This is so cool and satisfying to watch!!!! Awesome stuff dude keep if up!!

  • @silent.-killer
    @silent.-killer Před 3 lety

    Loving the videos man! I was wondering if you would be able to do a video talking about some of the applications of web scraping?
    I've watched quite a few of your videos and you have said that Upwork pays peanuts for this kind of work so I think people would be curious to hear your opinion on how real value can be created with the data obtained while web scraping.
    Keep up the good work, this channel is honestly a gem.

  • @calvint678
    @calvint678 Před 3 lety

    Good stuff man. Thank you. Wish I had found this a year ago 💪🏽

  • @yusufyuksek41
    @yusufyuksek41 Před 3 lety

    That was very helpful. Thank you!

  • @rishijoshi5808
    @rishijoshi5808 Před 3 lety

    Wow, that was amazing! Thank you soo much!

  • @CodePhiles
    @CodePhiles Před 3 lety

    great work , you always bring new ideas to the table, Thanks a lot

  • @Emocar2
    @Emocar2 Před 3 lety

    great vid ...also your tone is great for this video👍🏻

  • @swaroop6418
    @swaroop6418 Před 3 lety +1

    Explained very well 👏

  • @YahiaHegazy
    @YahiaHegazy Před 3 lety +4

    Informative, educational and funny!

  • @CampbellMurphy
    @CampbellMurphy Před 3 lety

    Hey Adam, I really enjoy your videos! The MIM technique was very cool. Have you considered making a video about accessing Financial Data on Xero? They have a robust API and can provide a free demo account to query.

  • @irfanshaikh262
    @irfanshaikh262 Před 9 měsíci

    2:28 offcourse Adam. Will be really helpful

  • @oscarmartinezbeltran
    @oscarmartinezbeltran Před 3 lety

    !Great great Content, Thank you! Suggestion: Working with Facebook API and Google Ads API.

  • @rafnishad3523
    @rafnishad3523 Před 3 lety

    I have waited long for ur video. You should try to upload these videos earlier plzz..! and keep doing this good work
    thanks a lot :)

  • @milandemooij1749
    @milandemooij1749 Před rokem +1

    Hey man! Can you maybe quickly explain how you set up your iPhone mirroring on your MacBook and how you connected it to mitmproxy?

  • @syedhyder5630
    @syedhyder5630 Před 3 lety

    Sir. I am really excited by your videos. Thanks a lot sir. I will be very much greatful to you if you suggest any course online to learn web scraping. I have completed intermediate level python learning. I am looking forward to learn web scraping. Please help me by suggesting a course to learn sir. 🙏

  • @alexsantiago6109
    @alexsantiago6109 Před 2 lety

    Pretty awesome video. Are you still planning on making a setup video?

  • @gosu-team
    @gosu-team Před rokem

    Amazing tutorial, how do you stream mobile app UI on your mac?

  • @nikoscuatro7251
    @nikoscuatro7251 Před 3 lety

    what is that mobile simulator that you are using in the tutorial?

  • @haleemlahresh1581
    @haleemlahresh1581 Před 3 lety +1

    Hello MR
    I am a python learner who recently started learning about webscraping I've done some scraping programs for example I scraped comics chapters from a website which allowed me to do so any ways I wanted to ask you if you can help me start working on upwork by giving me tips on how I write my title and overview since I haven't worked before nor done any projects
    again thank you for you're content I find it very useful and helping its so appreciated .

  • @mdshajid2771
    @mdshajid2771 Před 3 lety +3

    you are the best :D

  • @siddharthkataria5650
    @siddharthkataria5650 Před rokem +1

    Please make a video on setting up mitm proxy

  • @islamibrahim4382
    @islamibrahim4382 Před 2 lety

    Hi bro like your content al lot, wanna ask you how to scrape real time data for the example in that video like what if i want to run it every hour without being blocked, how i can manage the headers and params

  • @RidwanurRahmanextreme
    @RidwanurRahmanextreme Před 19 dny

    Hi, How did you add your device with your laptop please?

  • @Thegillmor2010
    @Thegillmor2010 Před 3 lety +1

    have been looking for this for ages.. great tut... don't know python but managed to follow... The app I want to scrape requires a login also please can you show how to automate looping through the data (you mentioned it at 22:35) thanks again

    • @s3bbe1337
      @s3bbe1337 Před 3 lety

      To loop through all the pages, find the place in the code where he sends the "requests.get()" and put that inside a loop. Also include the params object and just increment the pages value for every loop.

    • @s3bbe1337
      @s3bbe1337 Před 3 lety

      A tip is to add a time.sleep(5) or something at the end of the loop so it doesn't spam the API and get you banned.

  • @MiguelHernandez-oe8tl
    @MiguelHernandez-oe8tl Před 3 lety

    Great video!
    Can you make a video to get the comments on a Facebook page?

  • @MVGaming77
    @MVGaming77 Před rokem +1

    How did you configure your iphone to listen to the proxy server? i could not

    • @MakeDataUseful
      @MakeDataUseful  Před rokem +1

      It can be a little tricky, once I had the proxy running on the computer I set the phones proxy to the computers ip with port 8080 then I navigated to mitm.it in the browser which took me to a local site hosted by mtimproxy to download the certificate. Oncce downloaded I went to settings and installed and after it was installed I went to General --> About --> Certificate Trust Settings and enabled it. That last but used to stump me.

  • @888felipe
    @888felipe Před 3 lety +2

    Very nice this MITMproxy. Could you show how to use it to figure out how to login to spotify desktop app or mobile app, login and create a playlist using python. Thanks a lot.

    • @MakeDataUseful
      @MakeDataUseful  Před 3 lety +2

      Oooh good challenge! Let's add that one to the list... Here's hoping it's not a fail video!

    • @888felipe
      @888felipe Před 3 lety +1

      @@MakeDataUseful why would you fail. Your skills are impressive Learning a lot with you. Thank you.

  • @kennykenken4567
    @kennykenken4567 Před rokem

    Does this work on windows with iPhone?

  • @thatoneguy1821
    @thatoneguy1821 Před 24 dny

    Are you familiar with the DoorDash driver app? Is it possible to scrape data from that using MITM. Specifically, what I’m hoping for is a way to scrape all of my earnings from my time as a DoorDash driver (orders, stores, dates, base pay & tip).
    I’m not sure if you’ll even see this, but thanks in advance. I really appreciate these videos. Excellent content!

    • @MakeDataUseful
      @MakeDataUseful  Před 24 dny +1

      Hey! Maybe!! There’s a couple of considerations 1) if you can see the data on screen you’re likely able to see it in an API call and 2) if they are NOT using ssl certificate pinning. Pinning is where the app doesn’t trust certificates on the device and uses its own certificates. There are ways around it but require some extra steps. Shoot me an email youtube@makedatauseful.com.au and we can explore a little more!

  • @zecool7041
    @zecool7041 Před 3 lety +1

    nice video, I have one request if you can fulfill it , can you put the ipynb file somewhere where we can grab it , maybe Github or something, that way we can grab some parts of the code that we cant generate automatically, like in this case where I cant export request as a curl command because I'm using windows mitmweb, thanks for the answer !!

    • @alendujmic2621
      @alendujmic2621 Před 3 lety

      Did you find how to get curl command on windows mitmweb?

  • @eclipsed7209
    @eclipsed7209 Před 3 lety +2

    please do more

  • @sassydesi7913
    @sassydesi7913 Před 3 lety +1

    Here from Reddit.
    Can you tell if this can be used on teamblind.com? They have an infinite’s roll with encrypted payload. So difficult to grab data from that website.

    • @MakeDataUseful
      @MakeDataUseful  Před 3 lety

      Oooh encrypted payload, I do love a challenge. Let me check it out and get back to you shortly!

    • @MakeDataUseful
      @MakeDataUseful  Před 3 lety

      okay good news, someone has done a little digging and uncovered how they are encrypting and decrypting the payloads www.mdeditor.tw/pl/pQkk
      This is written in JS but it wouldn't take much effort to replicate in Python.

  • @rahalmehdiabdelaziz8121

    Adam, I'm one of your fun ... where is your LinkedIn , twitter ... etc

  • @djmill8000
    @djmill8000 Před rokem

    How you setup mitm

  • @tikendraw
    @tikendraw Před 3 lety

    Please can you make a tutorial on how to make a legit deal in upwork? As newbie l want to have a guiding hand to start the work.❤️ please.

  • @LongNguyen-jd9rr
    @LongNguyen-jd9rr Před rokem

    Is there a way to scrape the data from mitmweb using python?

    • @MakeDataUseful
      @MakeDataUseful  Před rokem

      Hey Long! I would use MITM Dump for programmatically scraping payloads with Python. It does a really great job, there is a basic example on the MITM website. Let me know how you go and if a tutorial would help.

  • @dongeunpaeng9353
    @dongeunpaeng9353 Před 3 lety

    3:18 how did he put his phone up to the screen? does anybody know how?

    • @MakeDataUseful
      @MakeDataUseful  Před 3 lety

      I think he was using a Mac program called Screenflow

  • @syedhyder5630
    @syedhyder5630 Před 3 lety +1

    export.clip curl @focus

    • @MakeDataUseful
      @MakeDataUseful  Před 3 lety +1

      Thank you! I almost forgot it again!! The project's open source, maybe we should build a "copy as python request" 😃

  • @hummer7345
    @hummer7345 Před 7 měsíci

    can you please tell me how to use this tool (mitmproxy) thanks.

  • @icinemagr4621
    @icinemagr4621 Před 2 lety

    a noob is using mitmproxy LOL

    • @MakeDataUseful
      @MakeDataUseful  Před 2 lety

      Hey thanks for dropping a comment, it got caught up in the CZcams spam filter. More MITMProxy videos?