[Mono-list] signcode on Centos 5
Matthew Gertner
matthew.gertner at gmail.com
Mon Dec 8 13:09:31 EST 2008
Hi,
I installed Mono using the yum packages on Centos 5. The version is
1.2.4-2.el5.centos.
I'm trying to digitally sign an executable using signcode. I followed
the instructions here:
https://developer.mozilla.org/En/Signing_an_executable_with_Authenticode.
I added the three CA certificates I downloaded from GlobalSign to the
CA repository as instructed.
I had to extract the .p7b and .pvk files from the .p12 file supplied
by GlobalSign, which I did by following the instructions here:
http://wiki.cacert.org/wiki/Authenticode.
Everything seemed to go fine, but when I run the signcode command:
signcode \
-spc (path to your public key).p7b \
-v (path to your private key).pvk \
-a sha1 -$ commercial \
-n My\ Application \
-i http://www.example.com/ \
-t http://timestamp.verisign.com/scripts/timstamp.dll \
-tr 10 \
MyApp.exe
I get the following output:
Mono SignCode - version 1.2.4.0
Sign assemblies and PE files using Authenticode(tm).
Copyright 2002, 2003 Motus Technologies. Copyright 2004-2006 Novell.
BSD licensed.
Unhandled Exception: System.FormatException: Invalid length.
at <0x00000> <unknown method>
at (wrapper managed-to-native)
System.Convert:InternalFromBase64String (string,bool)
at System.Convert.FromBase64String (System.String s) [0x00000]
at Mono.Security.Authenticode.SoftwarePublisherCertificate.CreateFromFile
(System.String filename) [0x00000]
at Mono.Tools.SignCode.GetCertificates (System.String spcfile) [0x00000]
at Mono.Tools.SignCode.Main (System.String[] args) [0x00000]
I get the same error if I just run:
signcode -spc <path to my p7b>
I'm stuck. Does anyone have any idea what might be causing this?
Thanks in advance,
Matt
More information about the Mono-list
mailing list