how to use sn.exe -Vr

孤人 提交于 2019-12-29 06:30:15

问题


From the MSDN help, it says the -Vr option is:

Registers assembly for verification skipping.

My question is when the -Vr is used, will it only change the assembly file itself or it will change the system registry as well. This matters whether I should issue this command in the development machine or in the final deployed machine.


回答1:


sn -Vr creates an entry in the registry on the local machine. It does not modify the assembly. You must run sn -Vr locally on every machine on which you wish to skip verification of the target assembly's strong name.

Since you mention that your concern is for a test machine, you may want to keep in mind that at least some of your test runs really ought to be run against the "as shipped" state of the application, which would include the final signature for assemblies. While I understand that key management concerns might preclude applying the final signature to, say, automated builds, you're eventually going to need to test using fully signed assemblies and no verification skipping if you want to emulate the eventual execution environment.




回答2:


Neither. You shouldn't skip verification on your deployment version.



来源:https://stackoverflow.com/questions/1845222/how-to-use-sn-exe-vr

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!