System.Reflection.AssemblyKeyFileAttribute Class

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

See Also: AssemblyKeyFileAttribute Members


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


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")].


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


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