I've seen a lot of people using CocoaPods to hash strings in RubyMotion. While this seemingly works (I wasn't able to get it to), there's an easier way.
A gem was released called 'RmDigest' which allows you to easily throw this functionality into your app. (In the background, it's actually utilizing the same Obj-C library.)
sha1 = RmDigest::SHA1.hexdigest('foo') md5 = RmDigest::MD5.hexdigest('bar')