Configure PreEmptive Protection™ DashO™ Renaming from three pages in the DashO user interface: Renaming - Options, Renaming - Exclude, and Renaming - Map Files. Use them to turn Renaming on, control how DashO creates new names, keep specific items from being renamed, and save the map files you need to decode stack traces.
To learn how Renaming works, see Renaming.
Prerequisites
- A DashO project in Standard Mode. The Renaming pages are only available in Standard Mode.
Configure Renaming Options
- Navigate to Renaming to open the Renaming - Options page.
- Choose how DashO renames methods:
- Overload Induction™: Uses the same new name for multiple methods with different signatures.
- Simple: Generates method names without creating additional overloading.
- Off: Disables the renaming feature.
- (Optional) Select Rename Annotations to rename internally defined annotations.
-
In the Classes/Packages section, configure the following settings:
Setting Description Classes Indicate if you want DashO to Rename classes or Keep names. Packages Indicate if you want DashO to Flatten hierarchy or Maintain hierarchy when renaming packages. Class Prefix Indicate an optional prefix to add to each new class name. Periods in the prefix place renamed classes in a different package. Alphabet Select the characters DashO uses for new class names. For more information, see Choose an Alphabet. Minimum Length Indicate the minimum length of the new class name DashO creates. Randomize Enable or disable randomized renaming for classes. -
Configure the Members box, configure the following settings:
Setting Description Members Indicate if you want DashO to Rename members or Keep names. Alphabet Select the characters DashO uses for new member names. For more information, see Choose an Alphabet. Minimum Length Indicate the minimum length of the new member name DashO creates. Randomize Enable or disable randomized renaming for members. - Save your project and build it to apply the changes.
Choose an Alphabet
Set the alphabet separately for classes and members.
- To use a predefined alphabet: Select any of the predefined alphabets in the Alphabet dropdown list.
- To create a custom alphabet: Enter the characters in the Alphabet field. A custom alphabet must follow the rules in Alphabets.
Exclude Items from Renaming
Use the Renaming - Exclude page to keep individual methods, fields, classes, or entire packages from being renamed. If you don't define any exclude rules, DashO doesn't exclude anything from Renaming.
The page uses the DashO rules editor. For details on creating, editing, and previewing rules, and on the fields in each rule dialog, see Graphical Rules Editor.
- Go to Renaming > Exclude to open the Renaming - Exclude page.
- Create a rule for each class, method, or field you want to keep from being renamed. For more information, see Graphical Rules Editor.
-
For each class rule, set Selects Class in the Class Rule dialog to choose what DashO excludes from Renaming:
Selects Class What DashO doesn't rename Selected The class itself. Cleared Only the members the class rule's method and field rules match. The class is just a container for those rules, and DashO still renames it. - To change this setting on an existing rule, select the rule, click Edit..., and select or clear Selects Class.
- (Optional) Preview your rules to confirm which items DashO won't rename. See Graphical Rules Editor.
- Save your project and build it to apply the changes.
Configure Map Files
DashO reads and writes Renaming Map Files to perform Incremental Obfuscation and to decode stack traces from your protected app.
- Go to Renaming > Map Files to open the Renaming - Map Files page.
- In Input, specify a Renaming Input Map File. DashO uses its names to perform Incremental Obfuscation. The map report notes input classes missing from the map, and classes in the map missing from the inputs.
- In Output, specify the Renaming Output Map File.
- In ProGuard-compatible Output, specify a ProGuard-compatible map file for analytics tools that support ProGuard map files.
- Select Overwrite to let DashO overwrite an existing file. DashO doesn't overwrite it by default.
- Save your project and build it to apply the changes.
Configure Related Settings on Other Pages
| Page | Setting | Use it to |
| Input — Options | Determine Reflected Classes | Have DashO find classes accessed through reflection and exclude them from Renaming. |
| Input — Options | Rename Reflected Classes | With Determine Reflected Classes, rename reflected classes and update references to them in String constants. |
| Output — Reports | Renaming report | Create a human-readable renaming report. |
Limitations and Troubleshooting
| Issue | Cause and resolution |
| The Renaming pages aren't visible. | They're only available in Standard Mode. In Android Mode, R8 handles renaming. |
| Renamed classes all end up in the default package. | DashO flattens the package hierarchy by default. Add a class prefix that includes a period, or retain the package hierarchy. |
| The build fails with a minimum length error. | Lower the Minimum Length or shorten the alphabet. |
| DashO doesn't update an existing map file. | Select Overwrite on the Renaming — Map Files page. |