Skip to content

feature: make watermark opt-in and configurable (#69 phase 1) - #97

Merged
mcpolo99 merged 1 commit into
developfrom
69-watermark-configurability
Jul 4, 2026
Merged

feature: make watermark opt-in and configurable (#69 phase 1)#97
mcpolo99 merged 1 commit into
developfrom
69-watermark-configurability

Conversation

@mcpolo99

@mcpolo99 mcpolo99 commented Jul 4, 2026

Copy link
Copy Markdown
Owner

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 at EndModule (after renaming), the attribute name survives verbatim into the output — a reliable de4dot / AV signature.

Change

  • ConfuserEngine no longer force-inserts the watermark rule → default output has no fingerprint attribute.
  • WatermarkingPhase now reads two params: text (attribute value, default = version) and attributeName (attribute type name, default = ConfusedByAttribute) — so it can be branded or disguised.
  • Documented the (previously undocumented) watermark protection.

⚠️ Behaviour change

Assemblies are no longer watermarked by default. Re-enable per project:
```xml




```

Test

Watermark.Test: (1) no ConfusedByAttribute when not requested; (2) custom text + attribute name applied when enabled. Both green.

Next phases (separate PRs)

  • Phase 2: randomize the easy magic constants (0x3dbb2819 / 0x3ddb2819 feedback + multipliers) via the Mutation system.
  • Phase 3: prime-modulus + xorshift/rotation randomization from curated valid sets.
  • Phase 4: uniquify.py source-level tool identity.

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.
@mcpolo99
mcpolo99 merged commit ee3a56c into develop Jul 4, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant