A way to see the code of existing apps?

Discussion in 'iPhone/iPad Programming' started by Paandaman, Feb 1, 2012.

  1. macrumors newbie

    Joined:
    Jan 26, 2012
    #1
    Hello everyone!

    Does anyone know if there is a program that let's you see the code of an existing app? I would like to get a bit more insight in how other people have constructed their apps. I know that there's some test apps that you can download from the apple-site but none of the apps there is in my interests.

    Thanks in advance!
     
  2. macrumors 68040

    Joined:
    Apr 22, 2005
    #2
    It is impossible to reverse engineer the Objective-C code from a compiled app.
     
  3. macrumors Core

    miles01110

    Joined:
    Jul 24, 2006
    Location:
    The Ivory Tower (I'm not coming down)
    #3
    You can e-mail the developer and ask for the code.
     
  4. macrumors 68040

    Joined:
    Apr 22, 2005
    #4
    You can also email Coke and KFC and ask for their secret recipes.
     
  5. macrumors 603

    ArtOfWarfare

    Joined:
    Nov 26, 2007
    #5
    Yes, and that'd be akin to asking Microsoft or Adobe for their code.

    Asking a developer for their code is more like asking your local mom and pop bakery about their recipe. There's a good chance they're friendly and will tell you some of it, if not all.

    And actually, I've emailed Coke before regarding how they make various packaging choices (school assignment a few years ago.) I got a very surprisingly detailed response.
     
  6. macrumors 68030

    PhoneyDeveloper

    Joined:
    Sep 2, 2008
  7. macrumors newbie

    johnjmapp

    Joined:
    Jan 17, 2012
    #7
    dont think there is any at the moment.
     
  8. Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #8
    There may be ways to decompile the executable of other apps, but you would lose a lot of what help makes that code understandable (variable names with meaning, comments, etc.)

    So, what is your area of interest?
     
  9. macrumors 6502

    dantastic

    Joined:
    Jan 21, 2011
    #9
    What you want to do instead is download a few open source projects from github and have a look how they are constructed. Open source projects tend to be well structured and ok-enough documented.

    This presuming you are looking to pick up best practices.
     
  10. thread starter macrumors newbie

    Joined:
    Jan 26, 2012
    #10
    Thanks a lot for the replies everyone, you've been really helpful:)
    Will try to go through some open sources then!

    ----------

    So, what is your area of interest?[/QUOTE]

    Currently i would like to know how to make it possible to see a list of all applications running or just existing on the phone. I have seen it on quite a lot of apps on the market but not on any open source document yet!
     
  11. dejo, Feb 2, 2012
    Last edited: Feb 2, 2012

    Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #11
    Really? Care to provide some examples?

    EDIT:

    Anyways, perhaps this blog post will help.
     
  12. macrumors 603

    Joined:
    Jul 29, 2003
    Location:
    Silicon Valley
    #12
    Reverse engineering is almost always possible with a lot effort and expertise on a rooted device to which you have physical access. But reverse engineering will not show you the original code for the app, only an equivalent that can produce the same compiled result, which is usually far less readable (but occasionally can be more readable for really badly coded apps).

    iOS App store app binaries are encrypted. But unencrypted info might include plists, object method and class names.

    Really, the only good way to see the actual source code of an app might be to politely ask the author of the app if they will send you a copy. Or even offer to buy the code.
     
  13. thread starter macrumors newbie

    Joined:
    Jan 26, 2012
    #13
    I have seen it in SBsettings where it's called appfolders. And please excuse me if i sound like some kind of smartass trying to prove his point, i'm just really unfamiliar with everything that has to do with programming. That link seems to be spot on! Cheers:)

    Thanks firewood, i'll see if i can get in contact with the developer then:)
     
  14. Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #14
    In that case, I suggest you put all your grand ideas on the back-burner for now and concentrate on just learning the fundamentals of programming. Get comfortable with the basics, build small, simple programs, tweak existing code to enhance it, learn more advanced concepts, apply them, etc. Then, in a few weeks (or months, realistically), you can revisit what you can possibly accomplish for your high school project.
     
  15. Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #15
    That's a Jailbroken app. To the best of my knowledge what you are asking to do is completely impossible on non-Jailbroken devices. The developers on these forums seem to mostly concentrate on targeting non-Jailbroken devices using the official SDK.
     
  16. macrumors 65816

    jnoxx

    Joined:
    Dec 29, 2010
    Location:
    Aartselaar // Antwerp // Belgium
    #16
    I do have 1 question about it though. When you run BUMP, you can collect information about other apps installed.. How does that happen >.> (not trying to prove a point or being smartass, just want to know).
     
  17. Moderator emeritus

    robbieduncan

    Joined:
    Jul 24, 2002
    Location:
    London
    #17
    All other apps? Or ones that respond to it or can be used with it in some way (I've never used BUMP but I assume it's showing a list of other apps that it can interact with). If it shows apps that can be used with BUMP does it only show apps that have previously been used with it? Or if you install a new app does it show in BUMP before you open/use the new app?

    I am basically wondering if BUMP exposes a custom URL scheme handler and the URLs the other apps use to open BUMP somehow encode the app and BUMP simply remembers them or if there is something clever going on.
     
  18. macrumors 6502

    dantastic

    Joined:
    Jan 21, 2011
    #18
    dejo posted a link a bit up: http://amitay.us/blog/files/how_to_detect_installed_ios_apps.php

    essentially, your app needs to keep a list of apps it has info on and test for each one by either urlscheme or executable name.
     
  19. macrumors 68000

    thewitt

    Joined:
    Sep 13, 2011
    #19
    Code requests from other programmers always intrigue me. We get requests every month through our support email address where people want to see source code for one of our apps.

    The answer is always no - unless you would like to pay for custom app development, then you will get source, and no we won't sell just one section of code...

    Commercial app developers do this for a living, don't expect them to give you their work for free.

    If you want free source code, there are plenty of open source, all volunteer projects out there you can peruse, as well as the Stanford podcasts at iTunes U and lots of books on programming iOS devices.
     
  20. macrumors 6502a

    Joined:
    May 1, 2010
    Location:
    California
    #20
    You might want to look at some of the books that are being offered. I just bought Learning Cocos 2D at 1/2 off and it has complete source code you can download.

    The upside to buying one of these kind of books, is that you get chapter after chapter explaining the source code.

    Look at the eBooks deal thread posted in this forum. I paid $9.99 for mine.

    On decompiling programs, I've had that happen before. Years ago a client bought a product that decompiled my program and they hired someone to take over so they wouldn't have to pay me. There's usually a way to do this, but you end up with very hard to read source code and it's not always in the high level languages. Hard to learn from, much better to learn from a good book.
     

Share This Page