Skip to content

Offsets are wrong for iOS 7.1+ #3

@AurelienRibon

Description

@AurelienRibon

The wipe function works fine on iOS 6 and 7.0, but on my iOS 7.1.1 phone, wiping a NSString crashes the phone. Actually, looking at the memory, I found that in IMSMemoryManager.h, the OFFSET_SSTRING should be 17. Long strings are ok, as well as NSData. However, Wiping NSNumber crashes the app too, so its offset should be wrong too.

I also found out that in your demo, when replacing the 16 byte string ("0123456789ABCDEF") by a 512 byte string, the string appears twice in memory (shown when selecting "2048" as memory view window), and the wipe function only clears the first occurence of the string. The resulting string is "" in the debugguer, but the original content can still be shown in the memory, which defeats the purpose of the library.

I'm not an expert, so I can't help you more on that, but you may find this useful to know.

Thanks for this project, this can become an awesome library for secure apps!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions