在 WiX 中静默安装根证书 [英] Silently install root certificate in WiX

查看:34
本文介绍了在 WiX 中静默安装根证书的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何从 WiX 静默安装根证书?我正在安装一些根证书和中间证书,对于根证书,系统显示确认对话框,显示基本证书属性和指纹.这是我拥有的相关代码,使用映射在命名空间 iis 中的 WixIIsExtension:

How can I silently install root certificates from WiX? I'm installing some root and intermediate certificates, and for root certificates the system displays confirmation dialog showing basic certificate properties and thumbprint. This is relevant code I have, using WixIIsExtension mapped in namespace iis:

<Binary Id="RootCa" SourceFile="Certificates\RootCa.cer" />

<DirectoryRef Id="TARGETDIR">
  <Component Id="RootCa" Guid="...">
    <iis:Certificate
      Id="RootCa"
      BinaryKey="RootCa"
      Name="RootCa"
      StoreLocation="currentUser"
      StoreName="root"/>
  </Component>
</DirectoryRef>

<Feature ...>
    <ComponentRef Id="RootCa" />
</Feature>

推荐答案

Sunil 提供的自定义操作相当于具有 StoreLocation="localMachine" 属性的 Certificate 组件.在我的情况下,无论如何安装在机器商店中更有意义,所以我会这样做.原始问题仍然存在:如何在用户存储中静默安装根证书.如果有人对该问题有答案,我会将其标记为正确答案.

Custom action that Sunil provided is equivalent to Certificate component with attribute StoreLocation="localMachine". In my case installing in machine store makes more sense anyway, so I'll go with that. Original question still remains: how to silently install root certificate in user store. If someone has an answer to that question I'll mark it as correct answer.

这篇关于在 WiX 中静默安装根证书的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆