cpu killer Posted June 20, 2004 Share Posted June 20, 2004 Hi. I'm looking for a solution to this question: so, I'd like to disassemble a strong named assembly, edit its IL a little and compile it again with different key pair. however, i want to keep the original public key. Is that possible? I think so, but don't know the right steps. Please help me. Thank you in advance. Link to comment Share on other sites More sharing options...
0 azcodemonkey Posted June 20, 2004 Share Posted June 20, 2004 God, I hope that's not possible. Unless you have the original private key, you can't use the same public key. That's the beauty of asymmetric encryption. Is this someone else's code, or did the original private key get lost? Link to comment Share on other sites More sharing options...
0 lexecutil Posted June 20, 2004 Share Posted June 20, 2004 Yeah you can't do that without the private key from what I've heard. But if you just want to edit an assembly of an application I think you can. Just edit it then save it again and then use app.exe.config to make the application redirect to the new version. (Not positive if that will work) :) Dan Link to comment Share on other sites More sharing options...
0 smurfiness Posted June 20, 2004 Share Posted June 20, 2004 Yeah you can't do that without the private key from what I've heard. But if you just want to edit an assembly of an application I think you can. Just edit it then save it again and then use app.exe.config to make the application redirect to the new version. (Not positive if that will work) :)Dan No, it wouldn't work. Any time you reference a strongly-named assembly, the CLR checks the contents of the assembly (some sort of hashing scheme). If you modify it without re-signing with the original key pair, the CLR will refuse to load the assembly. Link to comment Share on other sites More sharing options...
Question
cpu killer
Hi. I'm looking for a solution to this question:
so, I'd like to disassemble a strong named assembly,
edit its IL a little and compile it again with
different key pair. however, i want to keep the
original public key. Is that possible? I think so,
but don't know the right steps. Please help me.
Thank you in advance.
Link to comment
Share on other sites
3 answers to this question
Recommended Posts