none
给CAB文件签名后,怎么读取出签名是添加的备注信息?

    问题

  • 用证书给文件签名时有输入 “描述信息” 和“URL”两项, 请问怎么可以读取出这两项信息?
    2016年6月12日 4:14

答案

  • Hi,

    你可以尝试下调用X509Certificates类库读取,范例:

    using System.Security.Cryptography.X509Certificates;
     
    X509Certificate cert = X509Certificate.CreateFromSignedFile(filename);

    具体属性从X509Certificate中读取。

    参考链接(英文版):

    X509Certificate Class

    另外,你也可以尝试用下反射获取相关属性:

    type.GetProperty("属性名")

    Regards,

    Moonlight


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.



    2016年6月13日 8:18