Reinforcement:
Can increase security, anti – crack
Reinforcement method:
Data encryption (string, network data, sensitive data)
Apply shell (binary encryption)
Code confusion (class name, method name, code logic)
Wait…
Hardening solutions suitable for iOS:
Code obfuscation scheme:
1. Source confusion: class name, method name, protocol name
2. LLVM intermediate code IR confusion (prone to bugs)
Source obfuscation schemes are recommended.
How to do source obfuscation?
One, obfuscate core method names, class names, and so on through macro definitions without having to obfuscate everything
In the PCH file, define macros
Such as: #define buyVip DFDDS > buyVip > buyVip > buyVip > buyVip > buyVip > buyVip > buyVip > buyVip It’s gonna make it a lot harder for him to reverse
As a developer, it is particularly important to have a learning atmosphere and a communication circle. Here is an iOS communication group: 642363427. Welcome to join us, no matter you are small white or big bull, share BAT, Ali interview questions, interview experience, discuss technology, iOS developers exchange learning and growth together!
Note:
1. Do not confuse the system approach
2. Do not confuse custom initialization methods starting with init
3. The set method needs extra attention when obfuscating attributes
4. If the XIB SB uses confusing content, such as the associated class name, you need to manually modify it
5. You can add a special prefix to the confused symbols to distinguish them from the system’s own symbols
6. Too much confusion may be rejected by appstore. Please explain the purpose
Obfuscation tools:
Manual confusion is definitely tiring, so don’t worry:
iOS-class-guard
Class-dump is an extension of class-dump, which scans executable files for class names, method names, attribute names, etc. It also updates xiB and SB names
2. Encrypt the string
Perform xor transport to encrypt a string