code signing problem

B

Buthrakaur

Hello,
I just tried to sign my assemblies with my newly generated
certificate, but I get just error message when compiling the assembly.
I was following this article: http://www.codeproject.com/useritems/signcode.asp
, generated my certificate with blank password and afterwards used the
*.pfx file for signing in the VS project settings.

The error message:
genasm.exe(1) : error There was an error initializing . Invalid
public key of assembly (HRESULT: 0x8013141E)

I also tried to generate new pfx certificate file directly from VS
project options dialog, but the compiler exception persists. Is there
any method how to get the signing working?

I used a snk file succesfully before, but I need to create the
provisioning file for WM devices and didn't found any method how to
get public part of the certificate to be able to get the SHA and
base64 values for building _setup.xml provisioning file. Is there any
method how to install certificate from a snk file on the device?

And another question - I created some helloworld application which I
was able to sign in VS and compile succesfully. The output exe file is
but without any signed certificate. The only working method is using
the signtool.exe utility, which will really sign the assembly and add
the certificate to the end of file (it is visible in HEX-editor). Is
the sign dialog in VS just for strong name signing and not for code
signing?
 
G

Guest

Try using the Visual Studios test certificates. They can be found at
Microsoft Visual Studio 8\SmartDevices\SDK\SDKTools\TestCertificates
add the certificate under the Properties Devices tab by selecting the
authenticode signing check box and importing the certificate. You may need
to install the certificates on the device. You can do this using the
sdkcerts.cab file located in the sub directory from above. When you are
ready to release your project, go to Verisign and request a real
Mobile2Market certificate, sign you code, have Verisign sign it and you are
ready to go. I hope this helps.

Rick D.
Contractor
 
B

Buthrakaur

thanks for your comments. I just get it working - I followed the
tutorial on codeproject, but I thought the "sign" project property
would aldso authenticode sign my code which was wrong assumption - I
just have to use signtool directly and everythink works.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top