2015-11-13 Update: The content of this article is now outdated, and some configurations may have potential issues. Not recommended for use, for reference only.
2014-04-09 Update: Upgraded OpenSSL version (1.0.1f) and Nginx version to avoid the Heartbleed attack.
The blog now enforces HTTPS access. Visitors coming from non-search-engine sources will be automatically redirected to HTTPS. Besides providing more secure data transmission, this was also done to enable SPDY.
Enabling SPDY was actually quite a headache. Since I’m using Nginx (unlike Apache which has a direct SPDY module), I looked it up online and found out that Nginx versions 1.4.X and above come with SPDY/2 support built-in. So I went ahead and upgraded Nginx. After the upgrade, I wrote the configuration file, but when I tried to restart, I suddenly got this message:
nginx: [warn] nginx was built without OpenSSL NPN support, SPDY is not enabled for 0.0.0.0:443 in …..
It seemed SPDY failed to enable. When I tested it in the browser, although the site was accessible, SPDY was not actually working. I searched for the reason and discovered that the OpenSSL version was too old. So I figured I’d just upgrade it. I followed some online tutorials to upgrade, but after the upgrade, when I started Nginx again, I still got the same error. At that point I was completely lost and couldn’t figure out what went wrong. I checked the issue several more times but still couldn’t find the cause, so in the end I just restored the old configuration and gave up.
Continue reading “SSL & SPDY”