Import-module pspki doesn't import pspki module and hence I am not able to use Get-CertificateRequest command in a .net application (to be specific in a asp.net code behind page which is in C#). Can someone please guide me how do I use the pspki module on a c# page?
Comments: I don't experience in using the module in ASP.NET applications, but you can use PKI.Core.dll .NET library in your application. In general, the module is a wrapper for PKI.Core.dll library. The library exposes a lot of public APIs. In order to work with certificate requests, you can use X509CertificateRequest class: http://pkix2.sysadmins.lv/library/html/T_System_Security_Cryptography_X509CertificateRequests_X509CertificateRequest.htm which supports both, PKCS#10 and PKCS#7 certificate requests.
Comments: I don't experience in using the module in ASP.NET applications, but you can use PKI.Core.dll .NET library in your application. In general, the module is a wrapper for PKI.Core.dll library. The library exposes a lot of public APIs. In order to work with certificate requests, you can use X509CertificateRequest class: http://pkix2.sysadmins.lv/library/html/T_System_Security_Cryptography_X509CertificateRequests_X509CertificateRequest.htm which supports both, PKCS#10 and PKCS#7 certificate requests.