Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
429 views
in Technique[技术] by (71.8m points)

asp.net - How I do a sign an assembly that has already been built into a dll specifically flute.dll

The reason I want to sign the dll is because I want to add it to the Global Assembly Cache. The assembly is a css parsing engine written in Java and ported to J#. I use VS2008 so I can't make J# projects. It doesn't have a strong name key assigned to it and I have no idea how to do it now that it's built.

Anyone have any ideas?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

After a little searching, I found this post that explains one way of doing it.

Exerpt:

From a VS.NET command prompt, enter the following:

  1. Generate a KeyFile: sn -k keyPair.snk
  2. Obtain the MSIL for the provided assembly: ildasm providedAssembly.dll /out:providedAssembly.il
  3. Rename/move the original assembly: ren providedAssembly.dll providedAssembly.dll.orig
  4. Create a new assembly from the MSIL output and your assembly KeyFile: ilasm providedAssembly.il /dll /key=keyPair.snk

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...