Answer the question
In order to leave comments, you need to log in
Why doesn't the server accept an SSL certificate?
After configuring mod_ssl on the server (apache 2.2), a self-signed localhost.crt certificate and a localhost.key key
were created. The openssl.cnf config is as follows
# OpenSSL example configuration file.
# This is mostly being used for generation of certificate requests.
#
# This definition stops the following lines choking if HOME isn't
# defined.
HOME = .
RANDFILE = $ENV::HOME/.rnd
# Extra OBJECT IDENTIFIER info:
#oid_file = $ENV::HOME/.oid
oid_section = new_oids
# To use this configuration file with the "-extfile" option of the
# "openssl x509" utility, name here the section containing the
# X.509v3 extensions to use:
# extensions =
# (Alternatively, use a configuration file that has only
# X.509v3 extensions in its main [= default] section.)
[ new_oids ]
# We can add new OIDs in here for use by 'ca', 'req' and 'ts'.
# Add a simple OID like this:
# testoid1=1.2.3.4
# Or use config file substitution like this:
# testoid2=${testoid1}.5.6
# Policies used by the TSA examples.
tsa_policy1 = 1.2.3.4.1
tsa_policy2 = 1.2.3.4.5.6
tsa_policy3 = 1.2.3.4.5.7
####################################################################
[ ca ]
default_ca = CA_default # The default ca section
####################################################################
[ CA_default ]
dir = /etc/pki/CA # Where everything is kept
certs = $dir/certs # Where the issued certs are kept
crl_dir = $dir/crl # Where the issued crl are kept
database = $dir/index.txt # database index file.
#unique_subject = no # Set to 'no' to allow creation of
# several ctificates with same subject.
new_certs_dir = $dir/newcerts # default place for new certs.
certificate = /etc/pki/tls/certs/localhost.crt # The CA certificate
serial = $dir/serial # The current serial number
crlnumber = $dir/crlnumber # the current crl number
# must be commented out to leave a V1 CRL
crl = $dir/crl.pem # The current CRL
private_key = /etc/pki/tls/private/localhost.key# The private key
RANDFILE = $dir/private/.rand # private random number file
x509_extensions = usr_cert # The extentions to add to the cert
# Comment out the following two lines for the "traditional"
# (and highly broken) format.
name_opt = ca_default # Subject Name options
cert_opt = ca_default # Certificate field options
# концовку подрезал, если необходимо могу дополнить.
# openssl req -new -newkey rsa:1024 -nodes -keyout client01.key \
-subj /C=RU/ST=Msk/L=Msk/O=Inc/OU=Web/CN=usr/[email protected] \
-out client01.csr
# openssl ca -config ../tls/openssl.cnf -in client01.csr -out client01.crt -batch
# openssl pkcs12 -export -in client01.crt -inkey client01.key \
-certfile localhost.crt -out client01.p12 -passout pass:q1w2e3
Answer the question
In order to leave comments, you need to log in
It would be necessary to look at the virtual host (or root site) config, as well as those places where you screwed the ssl authorization.
Usually, some of the servers don't accept self-signed certificates because they won't be trusted by servers. It would be highly recommended that go through third party certificate authority such as Symatecn, GeoTrust, Thawte and RapidSSL.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question