generate pem file for qpsmtpd+ssl 465

{ Posted on Dec 06 2008 by lucas }

If you want to use qpsmtpd in port 465 you have to use ssl. The easiest way to do it is following the qpsmtpd instructions: http://wiki.qpsmtpd.org/config:smtps. But you have to create a certificate.

This is the simpliest way to do it:

  1. Use your favorite app manager for your linux distro. Install stunnel.
  2. cd /etc/ssl (in debian) and generate pem file.
  3. $openssl req -new -x509 -days 3650 -nodes -config openssl.cnf -out stunnel.pem -keyout stunnel.pem
  4. You have to fill in the next questions: Country Name, State or Province Name, Locality Name, Organization Name, Organizational Unit Name, Common Name and Email Address.
  5. After this step you will have a stunnel.pem file.
  6. $openssl gendh 512 >> stunnel.pem
  7. This generates Diffie-Hellman parameters, and appends them to the pem file.
  8. To check the process and verify the certificate is ok, type: “openssl x509 -subject -dates -fingerprint -in stunnel.pem” and check the information.

After having generate the pem file, follow the instructions and you will have qpsmtpd runing in 465 port properly.

Remember the stunnel version is 3 or the wrapper for version 3 built in version 4.

Post a Comment

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word