We should use Microsoft intermediate language Disassembler (Ildasm) tool to sing the dlls.
Download .Net Framework 2.0 from Microsoft if you don't already have it. Please
follow below step to sign the dlls.
Step 1: Deassemble your dlls
Open a Visual Studio Command Prompt and type the following command
C:\>ildasm /all /out= YourAssemblyName.il YourAssemblyName.dll
This will create a file YourAssemblyName.il which will be used next to sign and build.
Step 2: Rebuild and Sign the YourAssemblyName.dll
Rename or backup your original assembly.We need strong name key for sing the dll.
So you can use existing key(.snk) or Create new strong name key.The following
command will be creates a key pair called sgKey.snk
C:\>sn -k sgKey.snk
Now.It’s read to sign the Assembly using strong name key (sgKey.snk)
C:\>ilasm /dll /key= sgKey.snk YourAssemblyName.il
Step 3: Verify assembly was signed
We should verify whether the assembly singed properly or not. Use below to check the
sing status
sn -vf YourAssemblyName.dll
The output should be like below.
Assembly YourAssemblyName.dll' is valid
No comments:
Post a Comment