feature: make watermark opt-in and configurable (#69 phase 1) - #97
Merged
Conversation
Phase 1 of the unique-obfuscation-identity work (#69). The 'ConfusedByAttribute' watermark was force-inserted into every obfuscated assembly and carried the ConfuserEx version — an identifiable fingerprint that de4dot and AV heuristics match. It is now opt-in: - ConfuserEngine no longer force-inserts the watermark rule, so default output carries no fingerprint attribute unless <protection id="watermark" /> is set. - WatermarkingPhase reads two parameters: 'text' (attribute value, defaults to the version) and 'attributeName' (attribute type name, defaults to ConfusedByAttribute), so the watermark can be branded or disguised. - Documented the previously-undocumented protection in docs/protections.md. Behaviour change: assemblies are no longer watermarked by default. Re-enable per project with the watermark protection. Test: Watermark.Test verifies no fingerprint attribute when not requested, and the custom text/name are applied when enabled.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Phase 1 of #69 (unique obfuscation identity). Removes the single biggest surviving fingerprint in ConfuserEx output.
Part of #69.
Problem
Every obfuscated assembly carried a
ConfusedByAttribute("<ConfuserEx version>"), force-inserted by the engine (rule 0), undocumented and impossible to disable. Because it is added atEndModule(after renaming), the attribute name survives verbatim into the output — a reliable de4dot / AV signature.Change
ConfuserEngineno longer force-inserts the watermark rule → default output has no fingerprint attribute.WatermarkingPhasenow reads two params:text(attribute value, default = version) andattributeName(attribute type name, default =ConfusedByAttribute) — so it can be branded or disguised.watermarkprotection.Assemblies are no longer watermarked by default. Re-enable per project:
```xml
```
Test
Watermark.Test: (1) noConfusedByAttributewhen not requested; (2) custom text + attribute name applied when enabled. Both green.Next phases (separate PRs)
uniquify.pysource-level tool identity.