x509

Delphi 7 access Windows X509 Certificate Store

Hello, My questions if pretty simple: is there a simple way to access Windows X509 Certificate Store using Delphi 7? Before asking this questions I have googeled, but have not found any useful info Thank You ...

Using HTTPS with REST in Java

I have a REST server made in Grizzly that uses HTTPS and works wonderfully with Firefox. Here's the code: //Build a new Servlet Adapter. ServletAdapter adapter=new ServletAdapter(); adapter.addInitParameter( "com.sun.jersey.config.property.packages", "My.services"); adapter.addInitParameter( ResourceConfig.PROPERTY_CONTAINER_REQUE...

How to do asymmetric encryption with X509 certificates and C#?

I am looking to encrypt files with X509 certificates using public and private keys and send them to a remote server. How would I do this? Is this even possible? How do I generate the certificate and then the public and private key pairs? ...

Java: Invalid keystore format, when generated through code

This has been asked a couple of times, but none provide coded test cases. Here I give an example of the problem: programmatic generation of a Keystore (works) creation of certificate within that store (works) saving keystore to disk (works) listing keystore with keytool (works) loading the keystore programmatically (fails with IOExcep...

m2crypto custom certificate verification

I need to build an encrypted connection between two peers, and I need to authenticate both. Both peers already share a fingerprint (SHA256 hash) of the other peer public key. I'm not using X509 or OpenPGP keys/certs as they are too big and bulky for my needs and they don't fit in the security model. I'm trying to build a connection with...

iPhone web service calls to WCF Service with Certificate Authentication

We are a .Net shop that has standardized on WCF Services. We are in the processs of developing an iPhone application that needs to make secure web services calls to obtain data for the app. To ensure secure communiations we have enabled SSL on our web servers. But this does not ensure the service can only be consumed by authorized apps. ...

Get client certificate for page registration

I want to make a registration page for clients, that would only contain a button register and unregister. When the user would click on any of these 2 button he would should be prompted to select a client certificate from his computer. I would also like to extract the email address from the selected certificate. Is there any way of decla...

Implementation of Message Level Security using X509 certificates in DotNet

Message Level Security using X509 certificates in DotNet: Application 1 Certificate: Application 1 holds Certificate 1 and its Private Key Personal Store: Certificate 1 is installed in the Personal Store of Application 1 Trusted Store: Certificate 2’s public part is installed in the Trusted Store of Application 1 Encryption: Encryp...

C# WCF client configuration for X509 secured web service over https

Hi guys I been pulling my hair out for the past few days trying to connect to a web service using .Net 3.5 and WCF (have also tried using WSE 3.0) without much luck. The web service is hosted by a 3rd party and we can access via https. They also make use of X509 certificates for security, to sign the message. I've been given some basic...

Obtaining a signed x509 when using ECDSA keys

I am trying to sign some X509 certificates. My root private key is an ECDSA secp384r1. I am using bouncy castle. What seems to happen is that when generating the certificate signature, the Signature class used is unable to understand my ECDSA key. The code that generates is as follows: X509V3CertificateGenerator v3CertGen = new X50...

Revoke client X509 certificate

Hi, I have ASP.NET web service on windows server 2003. I have own certificate authority. I use own client certificate on authentification in web service. I make client certificate. I call web service, everything is ok. Then I revoke this certificate in certification authority. Certificate is in Revoked certificate. I call web service wi...

Windows asks for p12 password when installing p12 key generated by openssl

If I generate a p12 certificate with openssl as: - openssl pkcs12 -export -in myprivatecert.pem -nokeys -out mycert.p12 Even though I ask openssl to not export the private key, why does windows still require the private key password when installing the certificate. I figure I am missing something. Thanks in advance, David. ...

Parsing X509 DSS Certificate to get P, Q, G and Y

I am trying to parse a X509 Certificate that contains a Digital Signature Algorithm (DSA) public key. Using the javax.security.cert.X509Certificate class and getPublicKey() method I've been able to get P, Q, G and Y: P: 0279b05d bd36b49a 6c6bfb2d 2e43da26 052ee59d f7b5ff38 f8288907 2f2a5d8e 2acad76e ec8c343e eb96edee 11 Q: 036de1 G: ...

How do I use m2crypto to validate a X509 certificate chain in a non-SSL setting

I'm trying to figure out how to, using m2crypto, validate the chain of trust from a public key version of a X509 certificate back to one of a set of known root CA's when the chain may be arbitrarily long. The SSL.Context module looks promising except that I'm not doing this in the context of a SSL connection and I can't see how the infor...

How to generate CA signed x509 certificate by M2Crypto

I have a CSR file and CA keys Thanks ...

Where to store X509 certificate for Windows service?

I have a Windows service that will normally be run using the Local System Account (although in some installations it may as a specific user account). The service is using WCF, with communication secured using X509 certificates. My question is, where is the best place to store the certificate (and private key)? If using a certificate s...

PKCS#7 Signed Code Image extracting

Hi, I wanted to extract the Signer Informations from PKCS#7 Signed Code Image using C/CPP. I wanted to know the openssl API's. I am Able to extract Using bouncy castle (CMSSignedData). Please let me know the openssl API's which I can use in C/CPP to extract the each signers and signer informations and verify the Signers. is there any ...

How to get the Signature of a Self-Signed Certificate using X509Certificate or other .NET Class?

Hello I am trying to verify a root/self-signed certificate by trying to decrypt the signature with a known/trusted Public Key, then checking if the decrypted hash matches the original certificate hash. I get the remote certificate by using RemoteCertificateValidation callback on the sslStream class. The certificate is given as a X509C...

Reading a certificate signing request with c#

Hello, I want to read the contents of a csr in c#, however I haven't found any way to do it in c#. What I've found was the namespace System.Security.Cryptography.X509Certificates, but it only handles existing certificates, not certificate requests:/ Can anyone give me an hint about it? Thanks in advance. Jorge ...

How to extract CN from X509Certificate in Java?

Hi, I am using a SslServerSocket and client certificates and want to extract the CN from the SubjectDN from the client's X509Certificate. At the moment I call cert.getSubjectX500Principal().getName() but this of course gives me the total formatted DN of the client. For some reason I am just interested in the CN=theclient part of the DN...