gpt4 book ai didi

.net - PFX 强命名

转载 作者:行者123 更新时间:2023-12-04 08:50:15 25 4
gpt4 key购买 nike

我试图用 PFX 强命名一个程序集也用于数字签名的文件。 PFX 证书具有 CodeSigning 选项,由 CA 提供。 .

当我尝试使用它时,出现以下错误:

error MSB3325: Cannot import the following key file: myCert.pfx. The key file may be password protected. To correct this, try to import the certificate again or manually install the certificate to the Strong Name CSP with the following key container name: VS_KEY_B763CB2413AC1708



我试图删除它并使用重新安装 PFX
sn -d VS_KEY_B763CB2413AC1708
sn -i myCert.pfx VS_KEY_B763CB2413AC1708

但这没有用。我试图将证书放在证书存储中 - 这也没有改变任何事情。我尝试以管理员身份运行 Visual Studio 并执行 MSBuild从命令行。

我还尝试使用本地生成的证书(有效)延迟对程序集进行签名,然后使用
sn -R myAssembly.dll myCert.pfx

然后我收到以下错误:
Failed to re-sign the assembly -- Keyset does not exist

我在 ClickOnce Manifest Signing and Strong-Name Assembly Signing Using Visual Studio Project Designer's Signing Page, Signing Assemblies 中找到了代码签名证书的要求.看起来他们都见过面,但我可能遗漏了一些东西。我该如何解决这个问题?

最佳答案

我希望这将有助于快速解决。去

Visual Studio 项目属性 -> 签名 -> 登录程序集 -> 选择强名称文件 ->(下拉)选择浏览.. -> 选择 <您的>.pfx 文件 -> 确定**

瞧,你已经准备好执行你的项目了。

关于.net - PFX 强命名,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8212923/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com