Mysterious malware steals Apple credentials from jailbroken iOS devices

Some iOS users found a malicious library of unknown origin on their jailbroken devices

A malware campaign of yet-to-be-determined origin is infecting jailbroken iPhones and iPads to steal Apple account credentials from SSL encrypted traffic.

The threat was discovered after some users reported on Reddit that they experienced crashes in some applications as a result of a mysterious MobileSubstrate add-on called Unflod.

MobileSubstrate, now called Cydia Substrate, is a framework for jailbroken devices that allows developers to create modifications for iOS.

"This 'substrate' allows you to extend and to modify the behaviour of iOS in ways that are deliberately prohibited by Apple on unjailbroken devices, such as by hooking, or intercepting, system functions to make them do new and interesting (though sadly also perhaps dangerous) things," wrote Paul Ducklin, the head of technology for Asia-Pacific at antivirus vendor Sophos, in a blog post Monday.

It appears that someone created a dynamic library for Cydia Substrate that hooks the legitimate iOS SSLWrite function to read data before it's encrypted and sent over a secure SSL connection. The rogue library is called Unflod.dylib, but instances with the name framework.dylib have also been observed.

"It has been suggested that the choice of name might have something to do with the existence of a real tweak called Unfold," researchers from SektionEins, a security consultancy company based in Germany, said in a blog post discussing the threat. "The choice of name might therefore just be an attempt to hide in plain sight."

After hooking the SSLWrite function, the malware monitors traffic for authentication requests with Apple's services. It then extracts Apple IDs and passwords from the data and sends them to one of two hardcoded IP (Internet Protocol) addresses.

It's not clear how the malicious Unflod.dylib library gets installed on jailbroken devices, but users and researchers have advanced the possibility that packages from unofficial repositories might be the source of infection.

There's also some circumstantial evidence pointing to a Chinese connection, the library being digitally signed with a legitimate developer certificate issued by Apple in February to someone named Wang Xin.

"This person might be a fake persona, the victim of certificate theft or really involved," the SektionEins researchers said. "It is impossible for us to know, but Apple should be able to investigate from this information and terminate that developer account."

However, whether the developer certificate is valid or not doesn't really matter, because the malicious code doesn't need to be digitally signed to work on jailbroken devices in the first place.

"Currently the jailbreak community believes that deleting the Unflod.dylib/framework.dylib binary and changing the Apple ID's password afterwards is enough to recover from this attack," the SektionEins researchers said.

"However it is still unknown how the dynamic library ends up on the device in the first place and therefore it is also unknown if it comes with additional malware gifts. We therefore believe that the only safe way of removal is a full restore, which means the removal and loss of the jailbreak," the researchers added.

Join the CSO newsletter!

Error: Please check your email address.

Tags applicationstelecommunicationiosmobile securityMobile OSesSektionEinsmobilespywaremalwaresophosApplesecurity

More about AppleSophosWang

Show Comments

Featured Whitepapers

Editor's Recommendations

Solution Centres

Stories by Lucian Constantin

Latest Videos

  • 150x50

    CSO Webinar: Will your data protection strategy be enough when disaster strikes?

    Speakers: - Paul O’Connor, Engagement leader - Performance Audit Group, Victorian Auditor-General’s Office (VAGO) - Nigel Phair, Managing Director, Centre for Internet Safety - Joshua Stenhouse, Technical Evangelist, Zerto - Anthony Caruana, CSO MC & Moderator

    Play Video

  • 150x50

    CSO Webinar: The Human Factor - Your people are your biggest security weakness

    ​Speakers: David Lacey, Researcher and former CISO Royal Mail David Turner - Global Risk Management Expert Mark Guntrip - Group Manager, Email Protection, Proofpoint

    Play Video

  • 150x50

    CSO Webinar: Current ransomware defences are failing – but machine learning can drive a more proactive solution

    Speakers • Ty Miller, Director, Threat Intelligence • Mark Gregory, Leader, Network Engineering Research Group, RMIT • Jeff Lanza, Retired FBI Agent (USA) • Andy Solterbeck, VP Asia Pacific, Cylance • David Braue, CSO MC/Moderator What to expect: ​Hear from industry experts on the local and global ransomware threat landscape. Explore a new approach to dealing with ransomware using machine-learning techniques and by thinking about the problem in a fundamentally different way. Apply techniques for gathering insight into ransomware behaviour and find out what elements must go into a truly effective ransomware defence. Get a first-hand look at how ransomware actually works in practice, and how machine-learning techniques can pick up on its activities long before your employees do.

    Play Video

  • 150x50

    CSO Webinar: Get real about metadata to avoid a false sense of security

    Speakers: • Anthony Caruana – CSO MC and moderator • Ian Farquhar, Worldwide Virtual Security Team Lead, Gigamon • John Lindsay, Former CTO, iiNet • Skeeve Stevens, Futurist, Future Sumo • David Vaile - Vice chair of APF, Co-Convenor of the Cyberspace Law And Policy Community, UNSW Law Faculty This webinar covers: - A 101 on metadata - what it is and how to use it - Insight into a typical attack, what happens and what we would find when looking into the metadata - How to collect metadata, use this to detect attacks and get greater insight into how you can use this to protect your organisation - Learn how much raw data and metadata to retain and how long for - Get a reality check on how you're using your metadata and if this is enough to secure your organisation

    Play Video

  • 150x50

    CSO Webinar: How banking trojans work and how you can stop them

    CSO Webinar: How banking trojans work and how you can stop them Featuring: • John Baird, Director of Global Technology Production, Deutsche Bank • Samantha Macleod, GM Cyber Security, ME Bank • Sherrod DeGrippo, Director of Emerging Threats, Proofpoint (USA)

    Play Video

More videos

Blog Posts

Market Place