Dotfuscator User's Guide
Signing Section

The signing section allows you to specify if and how you want Dotfuscator to sign your strongly named output assemblies. For more information about assembly signing, see Dotfuscating Strong Named Assemblies.

The signing section is optional. If not present, your strongly named input assemblies will not be resigned after Dotfuscation, and Authenticode Digital Signing will not be applied.  

Specifying <key> Element

You can specify the key or key pair that you want Dotfuscator to use when signing with a <key> element. A <key> element can contain either a <file> or a <container> sub element. A <file> element references the file containing the key or key pair. A <container> element has a "name" attribute that specifies the name of the key container.

<file> Element
Copy Code
      <key>
        <file dir="c:\temp" name="key.snk" />
      </key>
<container> Element
Copy Code
      <key>
        <container name="foo"/>
      </key>

<resign> Element

To resign an assembly that was already signed before Dotfuscation, use a <resign> element. If the assembly has custom attributes that specify the key to use, you do not need a <key> element. If you wish to ignore the attributes, set the dontuseattributes option and provide a <key> element. If our assembly does not have custom attributes that specify the key, you must provide a <key> element.

This example tells Dotfuscator to ignore any custom attributes that specify the key and instead manually specifies a key file.

<resign> Element
Copy Code
  <signing>
    <resign>
      <option>dontuseattributes</option>
      <key>
        <file dir="c:\temp" name="key.snk" />
      </key>
    </resign>
    ...
  </signing>

<delaysign> Element

If your input assembly is delay signed and you want Dotfuscator to automatically complete the signing process, you can provide a <delaysign> element with a <key> sub-element.

<delaysign> Element
Copy Code
  <signing>
    ...
    <delaysign>
      <key>
        <file dir="c:\temp" name="key.snk" />
      </key>
    </delaysign>
  </signing>
See Also

Advanced Topics

 

 


© 2016 PreEmptive Solutions, LLC. All Rights Reserved.

www.preemptive.com