I'm simply trying to digitally sign a javascript file using a test certificate I create. In doing so, I hope to get the extended privileges in firefox associated with signed scripts.
Code: Select all
todd@diesel:~/Desktop/Cert$ makecert -sv test.pvk -n "CN=Tornado" test.cer
Mono MakeCert - version 1.2.3.1
X.509 Certificate Builder
Copyright 2002, 2003 Motus Technologies. Copyright 2004-2006 Novell. BSD licensed.
Success
todd@diesel:~/Desktop/Cert$ cert2spc test.cer test.spc
Mono Cert2Spc - version 1.2.3.1
Transform a set of X.509 certificates and CRLs into an Authenticode(TM) "Software Publisher Certificate"
Copyright 2002, 2003 Motus Technologies. Copyright 2004-2006 Novell. BSD licensed.
Success
todd@diesel:~/Desktop/Cert$ signcode -V -spc test.spc -v test.pvk -n "Tornado" -t "http://timestamp.verisign.com/scripts/timstamp.dll" -tr 10 -tw 10 test.js
Mono SignCode - version 1.2.3.1
Sign assemblies and PE files using Authenticode(tm).
Copyright 2002, 2003 Motus Technologies. Copyright 2004-2006 Novell. BSD licensed.
System.ArgumentException: inputCount
at System.Security.Cryptography.HashAlgorithm.TransformFinalBlock (System.Byte[] inputBuffer, Int32 inputOffset, Int32 inputCount) [0x00000]
at Mono.Security.Authenticode.AuthenticodeBase.GetHash (System.Security.Cryptography.HashAlgorithm hash) [0x00000]
at Mono.Security.Authenticode.AuthenticodeFormatter.Sign (System.String fileName) [0x00000]
Couldn't sign file 'test.js'.