Skip to content

Commit 23f27be

Browse files
author
Mike Richter
committed
PR 65: Merge rename-compat to master #15070
The only changes to PPiOS-Rename were documentation changes with regards to the combined usage of PPiOS-ControlFlow and PPiOS-Rename. This includes changes to the suggested names of targets/schemes so that they make more senses when the additional instructions in PPiOS-ControlFlow are followed. - Update README.md for combined usage #15070 - Refine combined usage text #15070 Related work items: #15070
2 parents 9139b2a + ece4fd5 commit 23f27be

File tree

1 file changed

+18
-20
lines changed

1 file changed

+18
-20
lines changed

README.md

Lines changed: 18 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -67,20 +67,20 @@ The basic process is:
6767
1. Ensure all local source code changes have been committed
6868
2. Build the program
6969
3. Analyze the program
70-
4. Obfuscate the sources
70+
4. Apply renaming to the sources
7171
5. Build the program again
7272

73-
For your first time using *PPiOS-Rename,* the following script (adjusted for your project) will perform the Analyze step:
73+
For your first time using *PPiOS-Rename,* the following command (adjusted for your project) will perform the Analyze step:
7474

7575
ppios-rename --analyze /path/to/program.app/program
7676

7777
The analyze process generates `symbols.map`, the file containing a symbol mapping that can be used to decode stack traces in the event of a crash. The symbols file created during a build that is released should always be archived for subsequent use.
7878

79-
Then the Obfuscate Sources step can be accomplished with the following:
79+
Then the Apply Renaming step can be accomplished with the following:
8080

8181
ppios-rename --obfuscate-sources
8282

83-
> Note: The Obfuscate Sources phase modifies the **source code** of your app, but you should not check in the changes it makes. If you do so, it will cause errors the next time you need to perform the Analyze phase, and will cause issues with Storyboards in the IDE. We recommend only using the Obfuscate Sources phase in your release (or automated) build process, and you should always clean/reset your source tree after the build, before doing any further development.
83+
> Note: The Obfuscate Sources phase (invoked in the Apply Renaming step) modifies the **source code** of your app, but you should not check in the changes it makes. If you do so, it will cause errors the next time you need to perform the Analyze phase, and will cause issues with Storyboards in the IDE. We recommend only using the Obfuscate Sources phase in your release (or automated) build process, and you should always clean/reset your source tree after the build, before doing any further development.
8484
8585
Once you are comfortable using *PPiOS-Rename,* it can be easier to use if you integrate it into your Xcode project as part of the build process. This can be set up with the following process:
8686

@@ -96,7 +96,7 @@ Once you are comfortable using *PPiOS-Rename,* it can be easier to use if you in
9696

9797
6. Select Build Phases.
9898

99-
7. Add a script phase by selecting the "+" and then selecting New Run Script Phase (it should run as the last phase, and will by default).
99+
7. Add a script phase by selecting the "+" (right above "Target Dependencies") and then selecting New Run Script Phase (it should run as the last phase, and will by default).
100100

101101
8. Rename the phase from "Run Script" to "Analyze Binary".
102102

@@ -106,28 +106,26 @@ Once you are comfortable using *PPiOS-Rename,* it can be easier to use if you in
106106
[[ "${SDKROOT}" == *iPhoneSimulator*.sdk* ]] && sdk="${SDKROOT}" || sdk="${CORRESPONDING_SIMULATOR_SDK_DIR}"
107107
ppios-rename --analyze --sdk-root "${sdk}" "${BUILT_PRODUCTS_DIR}/${EXECUTABLE_PATH}"
108108

109-
10. Go to Product | Scheme | Manage Schemes.
110-
111-
11. If Autocreate Schemes is enabled, a new scheme for the obfuscate target will have already been created, rename it to "Build and Analyze <original-scheme-name>".
109+
10. From the menu, select Product | Scheme | Manage Schemes.
112110

113-
12. Otherwise, create a new scheme for the Build and Analyze target.
111+
11. If Autocreate Schemes is enabled, a new scheme for the duplicated target will have already been created. Rename it to "Build and Analyze <original-scheme-name>", and close the dialog. Otherwise, create a new scheme for the Build and Analyze target.
114112

115-
13. Duplicate the original target again, and rename it to "Obfuscate Sources".
113+
12. Duplicate the original target again, and rename it to "Apply Renaming to <original-target-name>".
116114

117-
14. Delete all of the steps in this target.
115+
13. Delete all of the steps in this target.
118116

119-
15. If there are any target dependencies, delete them as well.
117+
14. If there are any target dependencies, delete them as well.
120118

121-
16. Add a script phase, and rename it to "Obfuscate Sources" (this should be the only real action for this target).
119+
15. Add a script phase, and rename it to "Apply Renaming to Sources" (this should be the only real action for this target).
122120

123-
17. Paste the following script, again adjusting for the correct path:
121+
16. Paste the following script, again adjusting for the correct path:
124122

125123
PATH="${PATH}:${HOME}/Downloads/PPiOS-Rename-v1.0.0"
126124
ppios-rename --obfuscate-sources
127125

128-
18. Edit the scheme (or add one) for this new target, renaming the scheme to "Obfuscate Sources".
126+
17. Edit the scheme (or add one) for this new target, renaming the scheme to "Apply Renaming to <original-scheme-name>".
129127

130-
19. These changes should be committed to source control at this point, since building the Obfuscate Sources target will change the sources in ways that shouldn't generally be committed.
128+
18. These changes should be committed to source control at this point, since building the target to Apply Renaming will change the sources in ways that shouldn't generally be committed.
131129

132130

133131
When ready to start testing an obfuscated build:
@@ -138,22 +136,22 @@ When ready to start testing an obfuscated build:
138136

139137
3. Commit or otherwise preserve the `symbols.map` file.
140138

141-
4. Build using the Obfuscate Sources scheme, which applies the renaming to the sources.
139+
4. Build using the Apply Renaming scheme, which applies the renaming to the sources.
142140

143141
5. Build using the original scheme.
144142

145143
6. Revert changes to the sources before continuing development.
146144

147-
Once the sources are obfuscated, the process of building and testing for different destinations can be repeated using the original scheme (step #5), as long as you haven't reverted the sources yet (step #6).
145+
Once renaming has been applied to the sources, the process of building and testing for different destinations can be repeated using the original scheme (step #5), as long as you haven't reverted the sources yet (step #6).
148146

149-
If you modify the original build target or scheme, be sure to delete and recreate the Build and Analyze target as above. Under certain conditions, the Obfuscate Sources target and scheme will need to be recreated as well.
147+
If you modify the original build target or scheme, be sure to delete and recreate the Build and Analyze target as above. Under certain conditions, the Apply Renaming target and scheme will need to be recreated as well.
150148

151149

152150
Using PPiOS-Rename with PPiOS-ControlFlow
153151
-------------------------
154152
*PreEmptive Protection for iOS - Rename* (*PPiOS-Rename)* provides the "renaming" obfuscation, which is the most-common type of obfuscation typically applied to applications to help protect them from reverse engineering, intellectual property theft, software piracy, tampering, and data loss. There are additional obfuscation techniques, however, that are critically important for serious protection of apps. [PreEmptive Solutions](https://www.preemptive.com/) offers another product, [PreEmptive Protection for iOS - Control Flow](https://www.preemptive.com/products/ppios), that includes additional obfuscation transforms. *PPiOS-Rename* is meant to work alongside *PPiOS-ControlFlow*; together they provide much better protection than either one alone can provide.
155153

156-
If you have both *PPiOS-Rename* and *PPiOS-ControlFlow*, no special instructions are required for using them together. Set each one up according to its documentation, and they will each perform their obfuscation without affecting the other.
154+
Simple instructions for using them together are available in the documentation for *PPiOS-ControlFlow*.
157155

158156

159157
Demonstration

0 commit comments

Comments
 (0)