Thank you so much for sharing this, for making it open source, and even more so for documenting it so well!
I've used F-Script (on the Mac) whenever I needed something like this. However, the Smalltalk syntax seems to limit its appeal, and I've wondered whether a similar tool leveraging JavaScript could really take off. What you have created is far more sophisticated than I ever imagined. Looking forward to digging into it more.
For those like me who find the Smalltalk syntax appealing, there's hope to make more of it (given Objective-C's roots, this makes every sense): http://objective.st/
That looks really cool, but maybe a little ambitious? I don't know what Apple's restrictions are for iOS apps these days, but last time I was in the iOS game, they didn't allow anything that wasn't written directly in ObjC or C.
I've been using cycript for a while now for reverse engineering iOS applications, and it's absolute witchcraft! You can tab-complete your way through objects, call arbitrary functions, -- it's a fantastic tool for any pen-testers doing work in the mobile space.
It's nice to see this project get some much needed love, I tried to compile it from source a while back and it was a nightmare.
I highly recommend reading the new manual: I have added tons of new features in the last few weeks. Example: you can now query live objects given a Class (I scavenge the heap looking for live memory ranges that are the right size and shape for that Class, or any subclass).
> I pronounce "cycript" using a "geminate S" or "long S". The result sounds a little like a stereotypical serpent from a cartoon: "sssscript". I doubt anyone else will pronounce it like this, but I have my hopes.
I can relate. Okay, I'll pronounce it that way! :)
This is a feature from "JavaScript 1.7" (the versions after 1.5 are Firefox-only). There is a similar feature in ECMAScript 6, but the syntax is slightly different. I support both the Firefox-specific syntax and the current ECMAScript draft. (But yeah, if you try that expression without the Objective-C @ symbol in Firefox, it will actually work.)
Great job! thank you saurik for all the effort and help.
I'm having a small problem when attaching with the new version when on iPhone5 iOS7
(gdb) r
Starting program: /usr/bin/cycript
Reading symbols for shared libraries + done
Reading symbols for shared libraries ++++................................................. done
cy#
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0x00000010
0x000127bc in CYDisplayMove ()
(gdb) where
#0 0x000127bc in CYDisplayMove ()
#1 0x00012b50 in CYDisplayUpdate ()
#2 0x0015c9ae in readline_internal_setup ()
#3 0x0015d16e in readline ()
#4 0x0000b2fc in Main ()
#5 0x0000e668 in main ()
That code is old. http://gitweb.saurik.com/cycript.git. (This link is on the website in the menu at the bottom.) (I should probably put a "code now in git" notice on that Subversion repository, like I had done for most of my other projects.)
I've used F-Script (on the Mac) whenever I needed something like this. However, the Smalltalk syntax seems to limit its appeal, and I've wondered whether a similar tool leveraging JavaScript could really take off. What you have created is far more sophisticated than I ever imagined. Looking forward to digging into it more.