<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.csclub.uwaterloo.ca/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=A3thakra</id>
	<title>CSCWiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.csclub.uwaterloo.ca/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=A3thakra"/>
	<link rel="alternate" type="text/html" href="https://wiki.csclub.uwaterloo.ca/Special:Contributions/A3thakra"/>
	<updated>2026-04-08T11:47:04Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.44.0</generator>
	<entry>
		<id>https://wiki.csclub.uwaterloo.ca/index.php?title=SSL&amp;diff=4324</id>
		<title>SSL</title>
		<link rel="alternate" type="text/html" href="https://wiki.csclub.uwaterloo.ca/index.php?title=SSL&amp;diff=4324"/>
		<updated>2020-01-28T06:56:23Z</updated>

		<summary type="html">&lt;p&gt;A3thakra: /* letsencrypt */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== GlobalSign ==&lt;br /&gt;
&lt;br /&gt;
The CSC currently has an SSL Certificate from GlobalSign for *.csclub.uwaterloo.ca provided at no cost to us through IST.  GlobalSign likes to take a long time to respond to certificate signing requests (CSR) for wildcard certs, so our CSR really needs to be handed off to IST at least 2 weeks in advance. You can do it sooner – the certificate expiry date will be the old expiry date + 1 year (+ a bonus )  Having an invalid cert for any length of time leads to terrible breakage, followed by terrible workarounds and prolonged problems.&lt;br /&gt;
&lt;br /&gt;
When the certificate is due to expire in a month or two, syscom should (but apparently doesn&#039;t always) get an email notification. This will include a renewal link. Otherwise, use the [https://uwaterloo.ca/information-systems-technology/about/organizational-structure/information-security-services/certificate-authority/globalsign-signed-x5093-certificates/self-service-globalsign-ssl-certificates IST-CA self service system]. Please keep a copy of the key, CSR and (once issued) certificate in &amp;lt;tt&amp;gt;/home/sysadmin/certs&amp;lt;/tt&amp;gt;. The OpenSSL examples linked there are good to generate a 2048-bit RSA key and a corresponding CSR. It&#039;s probably a good idea to change the private key (as it&#039;s not that much effort anyways). Just sure your CSR is for &amp;lt;tt&amp;gt;*.csclub.uwaterloo.ca&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
At the self-service portal, these options worked in 2013. If you need IST assistance, [mailto:ist-ca@uwaterloo.ca ist-ca@uwaterloo.ca] is the email address you should contact.&lt;br /&gt;
  Products: OrganizationSSL&lt;br /&gt;
  SSL Certificate Type: Wildcard SSL Certificate&lt;br /&gt;
  Validity Period: 1 year&lt;br /&gt;
  Are you switching from a Competitor? No, I am not switching&lt;br /&gt;
  Are you renewing this Certificate? Yes (paste current certificate)&lt;br /&gt;
  30-day bonus: Yes (why not?)&lt;br /&gt;
  Add specific Subject Alternative Names (SANs): No (*.csclub.uwaterloo.ca automatically adds csclub.uwaterloo.ca as a SAN)&lt;br /&gt;
  Enter Certificate Signing Request (CSR): Yes (paste CSR)&lt;br /&gt;
  Contact Information:&lt;br /&gt;
    First Name: Computer Science Club&lt;br /&gt;
    Last Name: Systems Committee&lt;br /&gt;
    Telephone: +1 519 888 4567 x33870&lt;br /&gt;
    Email Address: syscom@csclub.uwaterloo.ca&lt;br /&gt;
&lt;br /&gt;
== Certificate Location ==&lt;br /&gt;
&lt;br /&gt;
Keep a copy of newly generated certificates in /home/sysadmin/certs on the NFS server (currently [[Machine_List#aspartame|aspartame]]).&lt;br /&gt;
&lt;br /&gt;
A list of places you&#039;ll need to put the new certificate to keep our services running. Private key (if applicable) should be kept next to the certificate with the extension .key.&lt;br /&gt;
&lt;br /&gt;
* caffeine:/etc/ssl/private/csclub-wildcard.crt (for Apache)&lt;br /&gt;
* coffee:/etc/ssl/private/csclub.uwaterloo.ca (for PostgreSQL and MariaDB)&lt;br /&gt;
* mail:/etc/ssl/private/csclub-wildcard.crt (for Apache, Postfix and Dovecot)&lt;br /&gt;
* rt:/etc/ssl/private/csclub-wildcard.crt (for Apache)&lt;br /&gt;
* potassium-benzoate:/etc/ssl/private/csclub-wildcard.crt (for nginx)&lt;br /&gt;
* auth1:/etc/ssl/private/csclub-wildcard.crt (for slapd)&lt;br /&gt;
* auth2:/etc/ssl/private/csclub-wildcard.crt (for slapd)&lt;br /&gt;
* logstash:/etc/ssl/private/csclub-wildcard.crt (for nginx)&lt;br /&gt;
* mattermost:/etc/ssl/private/csclub-wildcard.crt (for nginx)&lt;br /&gt;
* load-balancer-0(1|2):/etc/ssl/private/csclub.uwaterloo.ca (for haproxy)&lt;br /&gt;
&lt;br /&gt;
Some services (e.g. Dovecot, Postfix) prefer to have the certificate chain in one file. Concatenate the appropriate intermediate root to the end of the certificate and store this as csclub-wildcard-chain.crt.&lt;br /&gt;
&lt;br /&gt;
== letsencrypt ==&lt;br /&gt;
&lt;br /&gt;
We support letsencrypt for our virtual hosts with custom domains. We use the &amp;lt;tt&amp;gt;cerbot&amp;lt;/tt&amp;gt; from debian repositories with a configuration file at &amp;lt;tt&amp;gt;/etc/letsencrypt/cli.ini&amp;lt;/tt&amp;gt;, and a systemd timer to handle renewals.&lt;br /&gt;
&lt;br /&gt;
The setup for a new domain is:&lt;br /&gt;
&lt;br /&gt;
# Become &amp;lt;tt&amp;gt;certbot&amp;lt;/tt&amp;gt; on caffine with &amp;lt;tt&amp;gt;sudo -u certbot bash&amp;lt;/tt&amp;gt; or similar.&lt;br /&gt;
# Run &amp;lt;tt&amp;gt;certbot certonly -c /etc/letsencrypt/cli.ini -d DOMAIN --logs-dir /tmp&amp;lt;/tt&amp;gt;. The logs-dir isn&#039;t important and is only needed for troubleshooting.&lt;br /&gt;
# Set up the Apache site configuration using the example below. (apache config is in /etc/apache2) Note the permanent redirect to https.&lt;br /&gt;
# Make sure to commit your changes when you&#039;re done.&lt;br /&gt;
# Reloading apache config is &amp;lt;tt&amp;gt;sudo systemctl reload apache2&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;VirtualHost *:80&amp;gt;&lt;br /&gt;
     ServerName example.com&lt;br /&gt;
     ServerAlias *.example.com&lt;br /&gt;
     ServerAdmin example@csclub.uwaterloo.ca&lt;br /&gt;
 &lt;br /&gt;
     #DocumentRoot /users/example/www/&lt;br /&gt;
     Redirect permanent / https://example.com/&lt;br /&gt;
 &lt;br /&gt;
     ErrorLog /var/log/apache2/example-error.log&lt;br /&gt;
     CustomLog /var/log/apache2/example-access.log combined&lt;br /&gt;
 &amp;lt;/VirtualHost&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 &amp;lt;VirtualHost csclub:443&amp;gt;&lt;br /&gt;
     SSLEngine on&lt;br /&gt;
     SSLCertificateFile /etc/letsencrypt/live/example.com/fullchain.pem&lt;br /&gt;
     SSLCertificateKeyFile /etc/letsencrypt/live/example.com/privkey.pem&lt;br /&gt;
     SSLStrictSNIVHostCheck on&lt;br /&gt;
 &lt;br /&gt;
     ServerName example.com&lt;br /&gt;
     ServerAlias *.example.com&lt;br /&gt;
     ServerAdmin example@csclub.uwaterloo.ca&lt;br /&gt;
 &lt;br /&gt;
     DocumentRoot /users/example/www&lt;br /&gt;
 &lt;br /&gt;
     ErrorLog /var/log/apache2/example-error.log&lt;br /&gt;
     CustomLog /var/log/apache2/example-access.log combined&lt;br /&gt;
 &amp;lt;/VirtualHost&amp;gt;&lt;/div&gt;</summary>
		<author><name>A3thakra</name></author>
	</entry>
</feed>