[Mono-list] Strong name support ?
Jaroslaw Kowalski
jaak@zd.com.pl
Sun, 26 Oct 2003 12:24:52 +0100
Hi!
I've recently updated mono & mcs from CVS and now mcs can't compile my
program anymore.
I use the attribute:
[assembly: AssemblyKeyName("mykey")]
to sign my assembly. Previously the attribute was just ignored, now the
compiler complains like this:
------------------
Unhandled Exception: System.IndexOutOfRangeException: Array index is out of
range
in <0x001df> Mono.Security.Cryptography.CryptoConvert:ToCapiPublicKeyBlob
(System.Security.Cryptography.RSA)
in <0x0006b> Mono.Security.Cryptography.CryptoConvert:ToCapiKeyBlob
(System.Security.Cryptography.RSA,bool)
in <0x0002d> Mono.Security.StrongName:get_PublicKey ()
in <0x00441> System.Reflection.Emit.AssemblyBuilder:SetCustomAttribute
(System.Reflection.Emit.CustomAttributeBuilder)
in <0x00cd4> Mono.CSharp.Attribute:ApplyAttributes
(Mono.CSharp.EmitContext,object,object,Mono.CSharp.Attributes)
in <0x001f9> Mono.CSharp.RootContext:EmitCode ()
in <0x0080e> Mono.CSharp.Driver:MainDriver (string[])
in <0x0001b> Mono.CSharp.Driver:Main (string[])
-------------------------
I found the sn.exe utility and ran the following commands to create the
keypair and put it into "mykey" container.
mono sn.exe -k mykey.snk
mono sn.exe -i mykey.snk mykey
but it didn't help. I'm running RedHat 9.
Any advice?
Jarek