certificate

How to create a working trusted and or self-signed certificate for a Windows 10 UWP application via Visual Studio 2019, 2017 and 2015

蓝咒 提交于 2019-12-17 22:35:36
问题 Per this documentation: https://docs.microsoft.com/en-us/windows-hardware/drivers/devtest/makecert The following command describes creating a windows cer-file (i.e. a certificate from a trusted provider.) The issue with this is that when building an application in visual studio 2017 it only allows, via the package.windows10.appxmanifest, a pfx file. when updating the this command line reference it doesn't produce a pvk file so one needs to add MakeCert -r -pe -ss PrivateCertStore -n "CN

Certificate subject X.509

不想你离开。 提交于 2019-12-17 21:41:01
问题 According to the X.509, a certificate has an attribute subject. C=US, ST=Maryland, L=Pasadena, O=Brent Baccala, OU=FreeSoft, CN=www.freesoft.org/emailAddress=baccala@freesoft.org This is the typical subject value. The question is what are the types(or tags) of those attributes(C, ST, L, O, OU, CN) and what is their format? 回答1: IETF PKIX (latest version RFC 5280) is a well accepted profile for certificates. From section 4.1.2.4, the following fields must be supported (I've added between

Export private key (PKCS#8) of CNG RSA certificate with oldschool .NET

狂风中的少年 提交于 2019-12-17 21:13:27
问题 I have a PKCS #12 (PFX) file that is a certificate with CNG RSA key and want to export the private key. MIIJ4gIBAzCCCZ4GCSqGSIb3DQEHAaCCCY8EggmLMIIJhzCCBgAGCSqGSIb3DQEHAaCCBfEEggXtMII F6TCCBeUGCyqGSIb3DQEMCgECoIIE/CCBPowHAYKKoZIhvcNAQwBAzAOBAjBalb3hEiYXQICB9AEggT Y80gGrPwpOpwdA1V9f55nVex6JzumPGb000ePt4jilZ3ktcY9SaE9krxBycNzRVFRVosJOZfHby8u2z 8PDj0bCgNUOE1yU5Jzf5yDyq1bRyLSi4zpwPaN5zj3CsJ3zqhvzzSmTRW2S4zeT1CgjQnsPkRHOMluX 0b+qNo

How to create self-signed certificate programmatically for WCF service?

筅森魡賤 提交于 2019-12-17 19:27:56
问题 I have a self-hosted WCF server running as a Windows service under the Local System account. I am trying to create a self-signed certificate programmatically in c# for use with a net.tcp endpoint using Message level security. I am using the following code which is very closely based on the accepted answer in How to create a self-signed certificate using C#? with some small changes trying to solve my problem. public static X509Certificate2 CreateSelfSignedCertificate(string subjectName,

Reading an X.509 certificate with Java

Deadly 提交于 2019-12-17 19:21:53
问题 I am trying to use Java to read a certificate that I received from an external party. The code is throwing the following error: java.lang.RuntimeException: java.security.cert.CertificateException: Unable to initialize, java.io.IOException: extra data given to DerValue constructor The code: FileInputStream ksfis = new FileInputStream(this.getCertificateFile()); ksbufin = new BufferedInputStream(ksfis); certificate = (X509Certificate) CertificateFactory.getInstance("X.509").generateCertificate

add or create 'Subject Alternative Name' field to self-signed certificate using makecert

倖福魔咒の 提交于 2019-12-17 18:43:06
问题 How can I create a certificate using makecert with a 'Subject Alternative Name' field ? You can add some fields eg, 'Enhanced Key Usage' with the -eku option and I've tried the -san option but makecert doesn't like it. This is a self-signed certificate so any method that uses IIS to create something to send off to a CA won't be appropriate. 回答1: Makecert doesn't appear to support SANs so I created a certificate with SANs for use with IIS using OpenSSL. Check out my post about it. http:/

What causes “Neither PUB key nor PRIV key:: nested asn1 error” when building a public key in ruby?

百般思念 提交于 2019-12-17 18:28:05
问题 When building a public key using the OpenSSL::PKey::RSA module by passing it a .pem file, what is the cause for a response: OpenSSL::PKey::RSAError: Neither PUB key nor PRIV key:: nested asn1 error from /Users/Matt/projects/placepop/lib/apn.rb:48:in `initialize' from /Users/Matt/projects/placepop/lib/apn.rb:48:in `new' from /Users/Matt/projects/placepop/lib/apn.rb:48:in `open' from (irb):1 Here is the source: cert = File.join(rails_root, 'config', 'apns', 'sandbox-cert.pem') APN_CONFIG = {

PHP - Swiftmailer using STARTTLS and self signed certificates

拟墨画扇 提交于 2019-12-17 18:23:58
问题 I'm trying to send an email with php and swiftmailer, using STARTTLS, but I'm getting a certificate error. I have root access to the SMTP server, and the certificate used is self-signed. I'm using Debian on both machines (web server and smtp server) PHP message: PHP Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed in [..]/lib/classes/Swift/Transport/StreamBuffer

PHP - Swiftmailer using STARTTLS and self signed certificates

*爱你&永不变心* 提交于 2019-12-17 18:21:04
问题 I'm trying to send an email with php and swiftmailer, using STARTTLS, but I'm getting a certificate error. I have root access to the SMTP server, and the certificate used is self-signed. I'm using Debian on both machines (web server and smtp server) PHP message: PHP Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed in [..]/lib/classes/Swift/Transport/StreamBuffer

ASP.NET - The specified network password is not correct

拟墨画扇 提交于 2019-12-17 18:17:39
问题 I have in my dev machine a WCF Client which requires certificate and it is working fine. After the deployment to production server I get the following Error: [CryptographicException: The specified network password is not correct.] DEV - Win7 32BIT IIS 7.5 PRODUCTION - Win SERVER 64BIT 2008 IIS 7.5 Even though there is no password between the networks and there is not certificate password. (I know because the dev works with no password). The only password that I have is the WCF one that is the