System.Reflection.AssemblyKeyFileAttribute Class

Specifies the name of a file containing the key pair used to generate a strong name.

See Also: AssemblyKeyFileAttribute Members

Syntax

[System.AttributeUsage(System.AttributeTargets.Assembly, Inherited=false)]
[System.Runtime.InteropServices.ComVisible(true)]
public sealed class AssemblyKeyFileAttribute : Attribute

Remarks

When building a strong-named assembly, the author must supply either this attribute or System.Reflection.AssemblyKeyNameAttribute. If System.Reflection.AssemblyDelaySignAttribute has also been specified, it is likely that this file will only contain the public key.

An example of the syntax is [assembly:AssemblyKeyFileAttribute("myKey.snk")].

Note:

Since the path and file name persist, ensure that the string you use with AssemblyKeyFileAttribute does not contain sensitive information.

Requirements

Namespace: System.Reflection
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0