<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
	<channel>
		<title>Sysadmin Blog</title>
		<link>https://www.cyberbyte.ch/blog/index.php</link>
		<description><![CDATA[Copyright Cyberbyte Networks]]></description>
		<copyright>Copyright 2026, Mike Rhyner</copyright>
		<managingEditor>info@cyberbyte.ch (Mike Rhyner)</managingEditor>
		<language>en-US</language>
		<generator>SPHPBLOG 0.8.1</generator>
		<item>
			<title>How to remove Private Key Password from pkcs12 container?</title>
			<link>https://www.cyberbyte.ch/blog/index.php?entry=entry240414-122546</link>
			<description><![CDATA[- Export to temporary pem file<br /><pre>openssl pkcs12 -in protected.p12 -nodes -out temp.pem<br />#  -&gt; Enter password<br /></pre><br /><br />- Convert pem back to p12<br /><pre>openssl pkcs12 -export -in temp.pem  -out unprotected.p12<br /># -&gt; Just press [return] twice for no password<br /></pre><br /><br />- Remove temporary certificate<br /><pre>rm temp.pem<br /></pre><br />]]></description>
			<category>OpenSSL</category>
			<guid isPermaLink="true">https://www.cyberbyte.ch/blog/index.php?entry=entry240414-122546</guid>
			<author>info@cyberbyte.ch (Mike Rhyner)</author>
			<pubDate>Sun, 14 Apr 2024 10:25:46 GMT</pubDate>
			<comments>https://www.cyberbyte.ch/blog/comments.php?y=24&amp;m=04&amp;entry=entry240414-122546</comments>
		</item>
		<item>
			<title>How do I verify that a private key matches a certificate?</title>
			<link>https://www.cyberbyte.ch/blog/index.php?entry=entry220211-124756</link>
			<description><![CDATA[To verify that an RSA private key matches the RSA public key in a certificate you need to i) verify the consistency of the private key and ii) compare the modulus of the public key in the certificate against the modulus of the private key.<br /><br />To verify the consistency of the RSA private key:<br /><pre>openssl rsa -check -noout -in myserver.key<br />RSA Key is ok</pre><br />If it doesn&#039;t say &#039;RSA key ok&#039;, it isn&#039;t OK!&quot;<br /><br />To view its modulus:<br /><pre>openssl rsa -modulus -noout -in myserver.key | openssl md5</pre><br />To view the modulus of the RSA public key in a certificate:<br /><pre>openssl x509 -modulus -noout -in myserver.crt | openssl md5</pre><br />If the first commands shows any errors, or if the modulus of the public key in the certificate and the modulus of the private key do not exactly match, then you&#039;re not using the correct private key.]]></description>
			<category>Technology, OpenSSL</category>
			<guid isPermaLink="true">https://www.cyberbyte.ch/blog/index.php?entry=entry220211-124756</guid>
			<author>info@cyberbyte.ch (Mike Rhyner)</author>
			<pubDate>Fri, 11 Feb 2022 11:47:56 GMT</pubDate>
			<comments>https://www.cyberbyte.ch/blog/comments.php?y=22&amp;m=02&amp;entry=entry220211-124756</comments>
		</item>
		<item>
			<title>Check CRL for revoked certificates and valitity of CRL itself</title>
			<link>https://www.cyberbyte.ch/blog/index.php?entry=entry220115-142316</link>
			<description><![CDATA[To find out if a client certificate was rejected or if the Certificate Revocation List itself is still valid (not older than &quot;Next Update&quot; attribute defined):<br /><pre>openssl crl -inform DER -text -noout -in mycrl.crl</pre><br />Most CRLs are DER encoded, but you can use -inform PEM if your CRL is not binary. If you’re unsure if it is DER or PEM open it with a text editor. If you see —–BEGIN X509 CRL—– then it’s PEM and if you see strange binary-looking garbage characters it’s DER.]]></description>
			<category>OpenSSL</category>
			<guid isPermaLink="true">https://www.cyberbyte.ch/blog/index.php?entry=entry220115-142316</guid>
			<author>info@cyberbyte.ch (Mike Rhyner)</author>
			<pubDate>Sat, 15 Jan 2022 13:23:16 GMT</pubDate>
			<comments>https://www.cyberbyte.ch/blog/comments.php?y=22&amp;m=01&amp;entry=entry220115-142316</comments>
		</item>
		<item>
			<title>Turning SSLv3 off on Apache Server to mitigate &quot;POODLE&quot; attack (CVE-2014-3566)</title>
			<link>https://www.cyberbyte.ch/blog/index.php?entry=entry141016-102212</link>
			<description><![CDATA[Add the following to your SSL configuration section:<br /><pre><br />   # Disable SSLv2 &amp; SSLv3 against POODLE issue (CVE-2014-3566)<br />    SSLProtocol All -SSLv2 -SSLv3<br /></pre><br />Note to insert this to <strong>all</strong> VirtualHost sections where SSL is enabled!<br /><br />Check your config:<br /><pre>apachectl configtest<br /></pre><br />Then restart apache server:<br /><pre>sudo service apache2 restart<br /></pre><br />To check if SSLv3 is turned off:<br /><pre>openssl s_client -connect <a href="http://www.ownspace.ch:443" >server.domain.tld:443</a> -ssl3<br /></pre><br />Then you shold see a message like this:<br /><pre>error:14094410:SSL routines:SSL3_READ_BYTES:sslv3 alert handshake failure:s3_pkt.c:1260:SSL alert number 40<br /></pre><br />To disable SSLv3 within other services:<br /><a href="http://askubuntu.com/questions/537196/how-do-i-patch-workaround-sslv3-poodle-vulnerability-cve-2014-3566" >see this post</a>]]></description>
			<category>Apache Stuff, OpenSSL</category>
			<guid isPermaLink="true">https://www.cyberbyte.ch/blog/index.php?entry=entry141016-102212</guid>
			<author>info@cyberbyte.ch (Mike Rhyner)</author>
			<pubDate>Thu, 16 Oct 2014 08:22:12 GMT</pubDate>
			<comments>https://www.cyberbyte.ch/blog/comments.php?y=14&amp;m=10&amp;entry=entry141016-102212</comments>
		</item>
		<item>
			<title>Check certificate on a server</title>
			<link>https://www.cyberbyte.ch/blog/index.php?entry=entry140604-182616</link>
			<description><![CDATA[Issue the following command:<br /><pre>openssl s_client -CApath /etc/ssl/certs/ -connect &lt;host.domian.tld&gt;:993</pre><br />For testing on a mail server supporting both non-encrypted and encrypted (TLS) connections using STARTTLS method:<br /><pre>openssl s_client -CApath /etc/ssl/certs/ -starttls smtp -connect &lt;host.domian.tld&gt;:25</pre><br /><br />There should be stated quite at end of command output:<br /><pre>    Verify return code: 0 (ok)</pre><br />before an eventual greeting message of the server.<br /><br />A bit above, you can check the certificate chain completeness:<br /><pre>Certificate chain<br /> 0 s:/description=3UwjnK9kRZ2wUo8e/C=CH/CN=domain1.ownspace.ch/emailAddress=hostmaster@ownspace.ch<br />   i:/C=IL/O=StartCom Ltd./OU=Secure Digital Certificate Signing/CN=StartCom Class 1 Primary Intermediate Server CA<br /> 1 s:/C=IL/O=StartCom Ltd./OU=Secure Digital Certificate Signing/CN=StartCom Class 1 Primary Intermediate Server CA<br />   i:/C=IL/O=StartCom Ltd./OU=Secure Digital Certificate Signing/CN=StartCom Certification Authority<br />---</pre><br />The last i(ssuer) is the root cert that most client will trust.]]></description>
			<category>Knowledge, OpenSSL</category>
			<guid isPermaLink="true">https://www.cyberbyte.ch/blog/index.php?entry=entry140604-182616</guid>
			<author>info@cyberbyte.ch (Mike Rhyner)</author>
			<pubDate>Wed, 04 Jun 2014 16:26:16 GMT</pubDate>
			<comments>https://www.cyberbyte.ch/blog/comments.php?y=14&amp;m=06&amp;entry=entry140604-182616</comments>
		</item>
		<item>
			<title>Create Private Key, Certificate Request and (optionally) self-signed cert using OpenSSL</title>
			<link>https://www.cyberbyte.ch/blog/index.php?entry=entry130211-200006</link>
			<description><![CDATA[First, set the common name (CN, ~FQDN) for the certificate:<br /><pre>CN=host.domain.tld</pre><br />Change to the directory where you would like to store the data relevant for certificates, e.g.:<br /><pre>cd /etc/ssl</pre><br />Then create a private key:<br /><pre>openssl genrsa -out private/${CN}.key 2048</pre><br />Generate the signing Request, either: <br />a) interactively, you&#039;ll have to answer some questions...:<br /><pre>openssl req -new -key private/${CN}.key -out ${CN}.csr</pre><br />b) using a customized openssl config file:<br /><pre>openssl req -new -config ${CN}-openssl.cnf -key private/${CN}.key -out ${CN}.csr</pre><br />Now you may either:<br />a) send the certificate request to an (official or internal) Certificate Authority to sign the Certificate<br /><br />b) for testing purposes only, you can also self-sign the certificate:<br /><pre>openssl x509 -req -days 1825 -in ${CN}.csr -signkey private/${CN}.key -out certs/${CN}.crt</pre><br />When you have received signed (or self-signed) certificate, you can copy all the files to the appropriate location.<br /><br />Probably you have to create a combined pkcs#12 (.p12, .pfx) file, containing private key and certificates:<br /><pre>openssl pkcs12 -export -in ${CN}.crt -certfile cafile.pem -inkey ${CN}.key -out ${CN}.pfx</pre>(where cafile.pem is the ca certificate bundle of issuing certificate authority)<br /><br />Clear the shell variable for the Common Name:<br /><pre>CN=</pre>]]></description>
			<category>Apache Stuff, OpenSSL</category>
			<guid isPermaLink="true">https://www.cyberbyte.ch/blog/index.php?entry=entry130211-200006</guid>
			<author>info@cyberbyte.ch (Mike Rhyner)</author>
			<pubDate>Mon, 11 Feb 2013 19:00:06 GMT</pubDate>
			<comments>https://www.cyberbyte.ch/blog/comments.php?y=13&amp;m=02&amp;entry=entry130211-200006</comments>
		</item>
		<item>
			<title>Simple SSL Certificate Authority</title>
			<link>https://www.cyberbyte.ch/blog/index.php?entry=entry040322-000000</link>
			<description><![CDATA[Sometimes, you need some SSL certificates for providing SSL encrypted pages.<br /><br />You can obtain a server certificate from Verisign or Entrust but they&#039;re quite expensive.<br /><br />Or you can make them yourself. Here are some tools to get there. I won&#039;t provide information about cryptology at all, neither you will find a professional PKI solution here.<br /><br />Creating your &quot;own CA&quot; makes only sense for sites where encryption should be in place, without providing official trusted credentials. Every user connecting to your secured site get a warning message every time he connects to your site, until he manually accept your CA Certificate.<br /><br />First you need OpenSSL, the code which deals with digital certificates.<br />    For information on the command options of the OpenSSL tools look at the OpenSSL <a href="http://www.openssl.org/docs/apps/openssl.html" >Documentation</a> (from openssl.org)<br />    Then get the SSL CA-Tools 0.2 (<a href="http://www.cyberbyte.ch/Linux/ssl.ca-0.2.tar.gz" >SSL CA-Tools 0.2</a>). This is a version slightly modified so you can also renew certificates easily.<br />    If you do prefer to use the original version, you can find it here: <a href="http://www.openssl.org/contrib/ssl.ca-0.1.tar.gz" >SSL CA-Tools</a>)<br /><br />The SSL CA-Tools are easy to use scripts which query the necessary information in a dialog and execute the appropriate openssl commands. Untar it somewhere, e.g. under your openssl directory, look at the README, and create a self-signed CA certificate, user- and server certificates and finally sign them with your CA key.]]></description>
			<category>Tools &amp; more, OpenSSL</category>
			<guid isPermaLink="true">https://www.cyberbyte.ch/blog/index.php?entry=entry040322-000000</guid>
			<author>info@cyberbyte.ch (Mike Rhyner)</author>
			<pubDate>Sun, 21 Mar 2004 23:00:00 GMT</pubDate>
			<comments>https://www.cyberbyte.ch/blog/comments.php?y=04&amp;m=03&amp;entry=entry040322-000000</comments>
		</item>
	</channel>
</rss>
