<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Learning Notes &#8211; Luxing Huang</title>
	<atom:link href="https://luxing.im/category/learning-notes/feed/" rel="self" type="application/rss+xml" />
	<link>https://luxing.im</link>
	<description>Thoughs and things</description>
	<lastBuildDate>Mon, 20 Jul 2020 03:38:47 +0000</lastBuildDate>
	<language>en-CA</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.7.2</generator>
<site xmlns="com-wordpress:feed-additions:1">58771605</site>	<item>
		<title>Make virtual ethernet the default</title>
		<link>https://luxing.im/make-virtual-ethernet-the-default/</link>
					<comments>https://luxing.im/make-virtual-ethernet-the-default/#respond</comments>
		
		<dc:creator><![CDATA[Luxing Huang]]></dc:creator>
		<pubDate>Mon, 20 Jul 2020 03:34:52 +0000</pubDate>
				<category><![CDATA[Learning Notes]]></category>
		<category><![CDATA[Techie Stuff]]></category>
		<category><![CDATA[ip]]></category>
		<category><![CDATA[route]]></category>
		<category><![CDATA[vm]]></category>
		<guid isPermaLink="false">https://luxing.im/?p=845</guid>

					<description><![CDATA[Recently I leased a server with 2 IPs, x.x.x.x and y.y.y.y from a VPS company. Their first IP is the primary one and is connected to my VM, the secondary IP y.y.y.y is there for me to use, but have not connected yet. Given the following status quo: The primary x.x.x.x is a great IP &#8230; <p class="link-more"><a href="https://luxing.im/make-virtual-ethernet-the-default/" class="more-link">Continue reading<span class="screen-reader-text"> "Make virtual ethernet the default"</span></a></p>]]></description>
										<content:encoded><![CDATA[<p>Recently I leased a server with 2 IPs, x.x.x.x and y.y.y.y from a VPS company. Their first IP is the primary one and is connected to my VM, the secondary IP y.y.y.y is there for me to use, but have not connected yet.</p>
<p><span id="more-845"></span><br />
Given the following status quo:</p>
<p>The primary x.x.x.x is a great IP and has good connectivity all over the world, however their y.y.y.y secondary IP has a premium networking route to certain places in the world in addition. I&#8217;d like to have both IP working in the mean time make y.y.y.y the default IP. My operating system is CentOS 7.</p>
<p>I would like to achieve the goal of:<br />
1. Add y.y.y.y to the system<br />
2. Make y.y.y.y the default IP, if seen from outside world.<br />
3. Keep the primary x.x.x.x IP available and connected just in case for failover.</p>
<p>So here is how I did it:</p>
<ol>
<li>Copy from ifcfg-eth0 to ifcfg-eth0:1 and change ifcfg-eth0:1 file in /etc/sysconfig/network-scripts</li>
<pre>
BOOTPROTO=none
DEFROUTE=yes
DEVICE=eth0:1
GATEWAY=y.y.y.1
HWADDR=be:ef:be:ef:be:ef
IPADDR=y.y.y.y
IPV6INIT=no
NETMASK=255.255.255.0
ONBOOT=yes
TYPE=Ethernet
USERCTL=no
</pre>
<p>Here BOOTPROTO must be none, make sure you keep the MAC address the same as ifcfg-eth0 and replace the values I obfuscated.</p>
<li>Modify ifcfg-eth0 file with DEFROUTE=no</li>
<li>Add a static route to make sure. Create a file route-eth0 in /etc/sysconfig/network-scripts</li>
<pre>
default via y.y.y.1 dev eth0:1
</pre>
<li>Restart network service</li>
<pre>systemctl restart network</pre>
<li>Confirm your IP and route</li>
<pre>
# confirm IP:
ip a

# confirm route:
ip ro
</pre>
</ol>
<p>And your VM&#8217;s default IP to the outside world should be y.y.y.y now.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://luxing.im/make-virtual-ethernet-the-default/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">845</post-id>	</item>
		<item>
		<title>Put CPU under Performance mode in Linux</title>
		<link>https://luxing.im/put-cpu-under-performance-mode-in-linux/</link>
					<comments>https://luxing.im/put-cpu-under-performance-mode-in-linux/#respond</comments>
		
		<dc:creator><![CDATA[Luxing Huang]]></dc:creator>
		<pubDate>Sun, 02 Feb 2020 07:13:46 +0000</pubDate>
				<category><![CDATA[Learning Notes]]></category>
		<category><![CDATA[Techie Stuff]]></category>
		<category><![CDATA[cpu]]></category>
		<category><![CDATA[frequency]]></category>
		<category><![CDATA[tuning]]></category>
		<guid isPermaLink="false">https://luxing.im/?p=832</guid>

					<description><![CDATA[Linux kernel is able to control every tiny bit of the hardware it operates. This time I am going to max out my server&#8217;s CPU performance by tuning the CPU to the performance mode. I have been renting a dedicated server for a long time, on the server I have been hosting a few virtual &#8230; <p class="link-more"><a href="https://luxing.im/put-cpu-under-performance-mode-in-linux/" class="more-link">Continue reading<span class="screen-reader-text"> "Put CPU under Performance mode in Linux"</span></a></p>]]></description>
										<content:encoded><![CDATA[<p>Linux kernel is able to control every tiny bit of the hardware it operates. This time I am going to max out my server&#8217;s CPU performance by tuning the CPU to the performance mode.</p>
<p><span id="more-832"></span></p>
<p>I have been renting a dedicated server for a long time, on the server I have been hosting a few virtual servers to serve my needs. In order to bring up the performance a little bit, I decide to bring the CPU frequency in high ranges at all times.</p>
<p>The raw way is to put <code>performance</code> (should be defined in <code>/sys/devices/system/cpu/cpu*/cpufreq/scaling_available_governors</code>) to <code>/sys/devices/system/cpu/cpu*/cpufreq/scaling_governor</code></p>
<p>Now if my server has 1 or 2 cores, I may just change the cpu0 and cpu1 values directly, but what if I have 32 cores or even more? Human errors will occur while scripting. We have command line tools to help us changing the governor instead, it is called <code>cpupower</code>.</p>
<p>All commands are run under root.</p>
<h3>Install cpupower</h3>
<p>On CentOS, cpupower is brought by <code>kernel-tools</code> package.</p>
<pre>yum install kernel-tools -y</pre>
<h3>Turn on cpupower service</h3>
<pre>
systemctl daemon-reload
systemctl enable cpupower
systemctl start cpupower
</pre>
<p>Now by your definition of the cpupower service, you may have already turned on performance mode, please check any of the scaling_governor file.</p>
<h3>Make machine performant</h3>
<pre>
cpupower frequency-set -g performance</h3>
</pre>
<p>You should be set. Check your CPU cores by <code>watch -s 2 cat /proc/cpuinfo</code> (control+c terminates watch)<br />
Your CPU cores should be running at high frequency range at all times.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://luxing.im/put-cpu-under-performance-mode-in-linux/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">832</post-id>	</item>
		<item>
		<title>Fix Music on Console TiMidity startup error</title>
		<link>https://luxing.im/fix-music-on-console-timidity-startup-error/</link>
					<comments>https://luxing.im/fix-music-on-console-timidity-startup-error/#respond</comments>
		
		<dc:creator><![CDATA[Luxing Huang]]></dc:creator>
		<pubDate>Mon, 19 Feb 2018 16:04:22 +0000</pubDate>
				<category><![CDATA[Learning Notes]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[moc]]></category>
		<category><![CDATA[music]]></category>
		<category><![CDATA[terminal]]></category>
		<guid isPermaLink="false">https://luxing.im/?p=749</guid>

					<description><![CDATA[I love to use terminal / console, figured that it is more efficient at most of the times, even when I was listening to music. Music On Console (MOC) is one of the programs that I use. My primary OS is Fedora and right now I am using Fedora 27. Strangely I failed to start &#8230; <p class="link-more"><a href="https://luxing.im/fix-music-on-console-timidity-startup-error/" class="more-link">Continue reading<span class="screen-reader-text"> "Fix Music on Console TiMidity startup error"</span></a></p>]]></description>
										<content:encoded><![CDATA[<p>I love to use terminal / console, figured that it is more efficient at most of the times, even when I was listening to music. Music On Console (MOC) is one of the programs that I use.<br />
<span id="more-749"></span></p>
<p>My primary OS is Fedora and right now I am using Fedora 27.</p>
<p>Strangely I failed to start <code>mocp</code> command once I installed moc, with a little searching, add <code>~/.moc/config</code> file with the content:</p>
<pre>TiMidity_Config = /etc/timidity.cfg</pre>
<p>Make sure this config file has 600 permission or it will complain about insecure permission.</p>
<p>Then I would be able to use mocp in any directory.</p>
<p>MOC has Equalizer support, <a href="http://ftp.daper.net/pub/soft/moc/contrib/eqsets.tar.gz">download</a> the eqset from their official website and the presets to <code>~/.moc/eqsets</code></p>
]]></content:encoded>
					
					<wfw:commentRss>https://luxing.im/fix-music-on-console-timidity-startup-error/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">749</post-id>	</item>
		<item>
		<title>Let Firefox support h264 video in Fedora</title>
		<link>https://luxing.im/let-firefox-support-h264-video-in-fedora/</link>
					<comments>https://luxing.im/let-firefox-support-h264-video-in-fedora/#respond</comments>
		
		<dc:creator><![CDATA[Luxing Huang]]></dc:creator>
		<pubDate>Sat, 23 Apr 2016 15:03:37 +0000</pubDate>
				<category><![CDATA[Learning Notes]]></category>
		<guid isPermaLink="false">https://luxing.im/?p=652</guid>

					<description><![CDATA[H264 decoder is proprietary. Hence no default installation on fresh Fedora. We need to add rpmfusion repositories and other packages to support firefox streaming/playing h264 format. First, install RPMFusion repo on Fedora 23: dnf install http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-23.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-23.noarch.rpm Now install the necessary h264 packages: dnf install gstreamer1-libav gstreamer1-vaapi gstreamer1-plugins-{good,good-extras,ugly} -y Restart your browser.]]></description>
										<content:encoded><![CDATA[<p>H264 decoder is proprietary. Hence no default installation on fresh Fedora. We need to add rpmfusion repositories and other packages to support firefox streaming/playing h264 format.<br />
<span id="more-652"></span></p>
<p>First, install RPMFusion repo on Fedora 23:</p>
<pre>dnf install http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-23.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-23.noarch.rpm</pre>
<p>Now install the necessary h264 packages:</p>
<pre>dnf install gstreamer1-libav gstreamer1-vaapi gstreamer1-plugins-{good,good-extras,ugly} -y</pre>
<p>Restart your browser.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://luxing.im/let-firefox-support-h264-video-in-fedora/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">652</post-id>	</item>
		<item>
		<title>Install XeLaTeX in Fedora</title>
		<link>https://luxing.im/install-xelatex-in-fedora/</link>
					<comments>https://luxing.im/install-xelatex-in-fedora/#respond</comments>
		
		<dc:creator><![CDATA[Luxing Huang]]></dc:creator>
		<pubDate>Fri, 08 Apr 2016 15:10:52 +0000</pubDate>
				<category><![CDATA[Learning Notes]]></category>
		<category><![CDATA[Personal]]></category>
		<category><![CDATA[latex]]></category>
		<category><![CDATA[xelatex]]></category>
		<guid isPermaLink="false">https://luxing.im/?p=639</guid>

					<description><![CDATA[A note to myself. I tried to install XeLaTeX to my freshly installed Fedora 23. sudo dnf install texlive-collection-fontsrecommended texlive-xetex texlive-latex texlive-titlesec 'tex(datetime.sty)' 'tex(eu1enc.def)' 'tex(polyglossia.sty)']]></description>
										<content:encoded><![CDATA[<p>A note to myself. I tried to install XeLaTeX to my freshly installed Fedora 23.<br />
<span id="more-639"></span></p>
<pre>sudo dnf install texlive-collection-fontsrecommended texlive-xetex texlive-latex texlive-titlesec 'tex(datetime.sty)' 'tex(eu1enc.def)' 'tex(polyglossia.sty)' </pre>
]]></content:encoded>
					
					<wfw:commentRss>https://luxing.im/install-xelatex-in-fedora/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">639</post-id>	</item>
		<item>
		<title>Fix SQLite3 dependency issue for dnf</title>
		<link>https://luxing.im/fix-sqlite3-dependency-issue/</link>
					<comments>https://luxing.im/fix-sqlite3-dependency-issue/#respond</comments>
		
		<dc:creator><![CDATA[Luxing Huang]]></dc:creator>
		<pubDate>Fri, 26 Feb 2016 18:48:02 +0000</pubDate>
				<category><![CDATA[Learning Notes]]></category>
		<category><![CDATA[Techie Stuff]]></category>
		<category><![CDATA[dnf]]></category>
		<category><![CDATA[rpm]]></category>
		<category><![CDATA[sqlite]]></category>
		<guid isPermaLink="false">https://luxing.im/?p=620</guid>

					<description><![CDATA[Recently when I did a dnf update I saw broken package for sqlite on my Fedora 23. Then I attempt to re-install that by removing it. rpm -e --nodeps sqlite Then shit hit the fan. When I then try to run rpm or dnf, both giving me errors. dnf gave me: Traceback (most recent call &#8230; <p class="link-more"><a href="https://luxing.im/fix-sqlite3-dependency-issue/" class="more-link">Continue reading<span class="screen-reader-text"> "Fix SQLite3 dependency issue for dnf"</span></a></p>]]></description>
										<content:encoded><![CDATA[<p>Recently when I did a <code>dnf update</code> I saw broken package for sqlite on my Fedora 23. Then I attempt to re-install that by removing it.</p>
<pre>rpm -e --nodeps sqlite</pre>
<p>Then shit hit the fan.<br />
<span id="more-620"></span></p>
<p>When I then try to run rpm or dnf, both giving me errors.</p>
<p>dnf gave me:</p>
<pre>
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib64/python3.4/sqlite3/__init__.py", line 24, in <module>
    from dbapi2 import *
  File "/usr/lib64/python3.4/sqlite3/dbapi2.py", line 27, in <module>
    from _sqlite3 import *
ImportError: File not found
</pre>
<p>And RPM gave me this error:</p>
<pre>error: Failed to initialize NSS library</pre>
<p>So rpm and dnf could not install packages. With a little searching around, I eventually figure out a way.</p>
<p>Step 1: Download sqlite3 from <a href="https://www.sqlite.org/download.html" target="_blank">https://www.sqlite.org/download.html</a><br />
Download the autoconf version of sqlite3 source code.</p>
<p>Step 2: compile. You need gcc and other tools. You better have this before this incident!</p>
<pre>./configure && make</pre>
<p>Step 3: Install those libs to /usr/local/lib</p>
<pre>make install</pre>
<p>Step 4：Using DNF to install.</p>
<pre>LD_LIBRARY_PATH=/usr/local/lib dnf --best install sqlite</pre>
<p>Should work.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://luxing.im/fix-sqlite3-dependency-issue/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">620</post-id>	</item>
		<item>
		<title>Multi Process Debugging</title>
		<link>https://luxing.im/multi-process-debugging/</link>
					<comments>https://luxing.im/multi-process-debugging/#respond</comments>
		
		<dc:creator><![CDATA[Luxing Huang]]></dc:creator>
		<pubDate>Wed, 29 Oct 2014 19:10:49 +0000</pubDate>
				<category><![CDATA[Learning Notes]]></category>
		<category><![CDATA[C]]></category>
		<category><![CDATA[debugging]]></category>
		<category><![CDATA[gdb]]></category>
		<category><![CDATA[multiprocessing]]></category>
		<category><![CDATA[multithreaded]]></category>
		<guid isPermaLink="false">https://luxing.im/?p=444</guid>

					<description><![CDATA[It bugs me to debug multiprocess C programs by using GDB. Here is a note for multi processing, and multithreaded debugging. gdb a.out Multi processes: Then: set follow-fork-mode child set schedule-multiple on set detach-on-fork off b ## r ## means a number, in this case, line number. Switching between processes: info inferiors inferior # In &#8230; <p class="link-more"><a href="https://luxing.im/multi-process-debugging/" class="more-link">Continue reading<span class="screen-reader-text"> "Multi Process Debugging"</span></a></p>]]></description>
										<content:encoded><![CDATA[<p>It bugs me to debug multiprocess C programs by using GDB. Here is a note for multi processing, and multithreaded debugging.</p>
<p><span id="more-444"></span></p>
<pre>
gdb a.out
</pre>
<p><strong>Multi processes:</strong></p>
<p>Then:</p>
<pre>
set follow-fork-mode child
set schedule-multiple on
set detach-on-fork off
b ##
r
</pre>
<p>## means a number, in this case, line number.</p>
<p>Switching between processes:</p>
<pre>
info inferiors
inferior #
</pre>
<p>In this case, # means process number.</p>
<p><strong>Multi Threads:</strong></p>
<pre>
info threads
thread #
</pre>
<p>Please consult the official docs for more features.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://luxing.im/multi-process-debugging/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">444</post-id>	</item>
		<item>
		<title>SSL Setup</title>
		<link>https://luxing.im/ssl-setup/</link>
					<comments>https://luxing.im/ssl-setup/#respond</comments>
		
		<dc:creator><![CDATA[Luxing Huang]]></dc:creator>
		<pubDate>Mon, 28 Jul 2014 18:14:19 +0000</pubDate>
				<category><![CDATA[Learning Notes]]></category>
		<category><![CDATA[nginx]]></category>
		<category><![CDATA[setup]]></category>
		<category><![CDATA[ssl]]></category>
		<guid isPermaLink="false">http://blog.luxing.im/?p=404</guid>

					<description><![CDATA[This is a personal technical note for SSL certificate setup, ensuring better scores at SSL Labs so that we have a better Internet security for our own. I use the built-in script provided from RHEL/CentOS to generate a private key. The location is under /etc/ssl/cert, by typing make site.key It will generate a private key. &#8230; <p class="link-more"><a href="https://luxing.im/ssl-setup/" class="more-link">Continue reading<span class="screen-reader-text"> "SSL Setup"</span></a></p>]]></description>
										<content:encoded><![CDATA[<p>This is a personal technical note for SSL certificate setup, ensuring better scores at <a href="https://www.ssllabs.com" target="_blank">SSL Labs</a> so that we have a better Internet security for our own.</p>
<p><span id="more-404"></span></p>
<p>I use the built-in script provided from RHEL/CentOS to generate a private key. The location is under <em>/etc/ssl/cert</em>, by typing</p>
<pre>make site.key</pre>
<p>It will generate a private key. Its actual command is:</p>
<pre>openssl genrsa -aes128 2048 </pre>
<p>You can adjust the key size for your own needs, but at least 2048 is needed for a relatively secure certificate.</p>
<p>Then we make its CSR by typing:</p>
<pre>make site.csr</pre>
<p>The actual command is:</p>
<pre>openssl req -new -key site.key -out site.csr -aes256</pre>
<p>The name <strong>site</strong> must be the same as the key name for the script to work. You can now copy and paste the CSR to whoever your trusted SSL Certificate Provider to sign. It doesn&#8217;t matter who choose to sign it as long as your user and you trust it, therefore I used <a href="https://www.CACert.org" target="_blank">CACert.org</a></p>
<p>Before we do anything else, we need to generate a different DH param. Let&#8217;s cd into /etc/nginx/ssl (or whatever you prefer), and do the following command:</p>
<pre>openssl dhparam -out dhparams.pem 2048</pre>
<p>Now we generate a custom DH param for securer DH. In the configuration next, we will use it.</p>
<p>Next, we need to setup a website that runs on SSL. Choosing the cipher is the most important part that prevents most of the crackers cracking decipher your server&#8217;s communication. The httpd side of software I choose is nginx, I like its versatility and efficiency.</p>
<p>Inside the server block, we must have the following lines:</p>
<pre>
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_ciphers "ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:DHE-DSS-AES128-GCM-SHA256:kEDH+AESGCM:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA256:DHE-RSA-AES256-SHA256: DHE-DSS-AES256-SHA:DHE-RSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA256:AES256-SHA256:AES128-SHA:AES256-SHA:AES:CAMELLIA:DES-CBC3-SHA:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!MD5:!PSK:!aECDH:!EDH-DSS-DES-CBC3-SHA:!EDH-RSA-DES-CBC3-SHA:!KRB5-DES-CBC3-SHA";
ssl_prefer_server_ciphers on;
ssl_session_cache shared:SSL:50m;
ssl_session_timeout 5m;

ssl_dhparam /etc/nginx/ssl/dhparams.pem;

add_header Strict-Transport-Security "max-age=31536000; includeSubdomains;"; # includeSubdomains only needed for the whole site encryption. You may or may not need it.

# The following settings only works with CA certified certs, not self-signed certs.
ssl_stapling on; 
resolver 8.8.8.8;
ssl_trusted_certificate /etc/nginx/ssl/root.crt; # Your CA Root cert.
</pre>
<p>The main purpose of Line 1 is to stop accepting requests from insecure protocols such as SSLv2, Line 2 restricts the cipher we will be using, and stop some insecure ciphers such as MD5 and RC4. If we add RC4 back on the list, we eliminate the chance to get BEAST attack, but will suffer RC4 attack. By removing RC4, some of the older browsers will not support visiting the website and possible to suffer BEAST attack. The future trend is, RC4 attack will get more sophisticated, and chance of BEAST attack will get smaller, I&#8217;d recommend to remove RC4 from the list.</p>
<p>Line 4 and 5 are for the SSL reuse, this can improve the performance. Line 6, 7, 8 are related to OCSP stapling, it enables the server to check the OCSP status, which can check the revocation of the certificates. The root.crt is the Class 1 PKI key of your CA.</p>
<p>Go to SSLLabs for a test, you might get an A+ if your signing authority is trusted!</p>
<p>Read more:<br />
<a href="http://crypto.stackexchange.com/questions/8933/how-can-i-use-ssl-tls-with-perfect-forward-secrecy" target="_blank">http://crypto.stackexchange.com/questions/8933/how-can-i-use-ssl-tls-with-perfect-forward-secrecy</a><br />
<a href="https://community.qualys.com/blogs/securitylabs/2013/08/05/configuring-apache-nginx-and-openssl-for-forward-secrecy" target="_blank">https://community.qualys.com/blogs/securitylabs/2013/08/05/configuring-apache-nginx-and-openssl-for-forward-secrecy</a><br />
<a href="http://googleonlinesecurity.blogspot.co.uk/2014/08/https-as-ranking-signal_6.html" target="_blank">http://googleonlinesecurity.blogspot.co.uk/2014/08/https-as-ranking-signal_6.html</a><br />
<a href="https://istlsfastyet.com/?utm_source=wmx_blog&#038;utm_medium=referral&#038;utm_campaign=tls_en_post" target="_blank">https://istlsfastyet.com/?utm_source=wmx_blog&#038;utm_medium=referral&#038;utm_campaign=tls_en_post</a><br />
<a href="http://chimera.labs.oreilly.com/books/1230000000545/ch04.html#TLS_RECORD_SIZE" target="_blank">http://chimera.labs.oreilly.com/books/1230000000545/ch04.html#TLS_RECORD_SIZE</a><br />
<a href="https://gist.github.com/plentz/6737338" target="_blank">https://gist.github.com/plentz/6737338</a><br />
<a href="http://nginx.org/en/docs/http/ngx_http_ssl_module.html#ssl_trusted_certificate" target="_blank">http://nginx.org/en/docs/http/ngx_http_ssl_module.html#ssl_trusted_certificate</a><br />
<a href="http://nginx.com/blog/nginx-poodle-ssl/" target="_blank">http://nginx.com/blog/nginx-poodle-ssl/</a><br />
<a href="https://weakdh.org/sysadmin.html" target="_blank">https://weakdh.org/sysadmin.html</a></p>
<p>Changelog:<br />
2014.08.13 &#8211; Added 3DES back to cipher suites for Windows XP compability.<br />
2014.10.17 &#8211; SSLv3 support is removed (POODLE). Strict Transport Security is added.<br />
2015.03.03 &#8211; RC4 removed and banned.<br />
2015.06.02 &#8211; Update DH strength</p>
]]></content:encoded>
					
					<wfw:commentRss>https://luxing.im/ssl-setup/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">404</post-id>	</item>
		<item>
		<title>Configuration on PS1 files in Vim</title>
		<link>https://luxing.im/configuration-on-ps1-files-in-vim/</link>
					<comments>https://luxing.im/configuration-on-ps1-files-in-vim/#respond</comments>
		
		<dc:creator><![CDATA[Luxing Huang]]></dc:creator>
		<pubDate>Tue, 29 Apr 2014 22:31:20 +0000</pubDate>
				<category><![CDATA[Learning Notes]]></category>
		<category><![CDATA[powershell]]></category>
		<category><![CDATA[ps1]]></category>
		<category><![CDATA[vim]]></category>
		<category><![CDATA[vimrc]]></category>
		<guid isPermaLink="false">http://blog.luxing.im/?p=375</guid>

					<description><![CDATA[Thank you Lixar for my first ever Co-op placement. Although there are many colleagues like me, love to use Linux/Unix as our main OS, work must be done as what we are expected. Because they choose Azure cloud initially, I have to do development work under Windows. It doesn&#8217;t bother me too much, I still &#8230; <p class="link-more"><a href="https://luxing.im/configuration-on-ps1-files-in-vim/" class="more-link">Continue reading<span class="screen-reader-text"> "Configuration on PS1 files in Vim"</span></a></p>]]></description>
										<content:encoded><![CDATA[<p>Thank you <a href="http://www.lixar.com" target="_blank">Lixar</a> for my first ever Co-op placement. Although there are many colleagues like me, love to use Linux/Unix as our main OS, work must be done as what we are expected. Because they choose Azure cloud initially, I have to do development work under Windows.</p>
<p>It doesn&#8217;t bother me too much, I still have my Linux as a guest VM on the second screen for transition. Now I need to study some PowerShell scripting.</p>
<p>Vim doesn&#8217;t support ps1 files for highlighting. So there is a <a href="http://www.vim.org/scripts/script.php?script_id=1327" target="_blank">plugin</a> for that. (Check out its github page for installation)<br />
<span id="more-375"></span><br />
I have linebreaks set up, I honour &#8220;80 chars per line&#8221; rule. I don&#8217;t think the nature of PowerShell honours that, at least not our internal scripts. Still I want to keep linebreaks in my vimrc, but to skip linebreaks for any ps1 files. A little bit of research and documentation lookup, add a line to my vimrc:</p>
<pre>autocmd BufRead,BufNewFile *.ps1    set nolbr</pre>
<p>It works perfectly.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://luxing.im/configuration-on-ps1-files-in-vim/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">375</post-id>	</item>
		<item>
		<title>Applying man with colour under zsh</title>
		<link>https://luxing.im/applying-man-with-colour-under-zsh/</link>
					<comments>https://luxing.im/applying-man-with-colour-under-zsh/#comments</comments>
		
		<dc:creator><![CDATA[Luxing Huang]]></dc:creator>
		<pubDate>Thu, 20 Feb 2014 15:42:45 +0000</pubDate>
				<category><![CDATA[Learning Notes]]></category>
		<category><![CDATA[Personal]]></category>
		<category><![CDATA[colour]]></category>
		<category><![CDATA[groff]]></category>
		<category><![CDATA[less]]></category>
		<category><![CDATA[man]]></category>
		<category><![CDATA[zshell]]></category>
		<guid isPermaLink="false">http://blog.luxing.im/?p=293</guid>

					<description><![CDATA[After installing zshell and applying the zshrc from grml system-wide, my man page doesn&#8217;t want to be colourful. The configuration is caused by a environmental variable GROFF_NO_SGR, when it&#8217;s set to 1, man page will be able to paint with colour. Here is my personal .zshrc: # Vim key binding bindkey -v # The important &#8230; <p class="link-more"><a href="https://luxing.im/applying-man-with-colour-under-zsh/" class="more-link">Continue reading<span class="screen-reader-text"> "Applying man with colour under zsh"</span></a></p>]]></description>
										<content:encoded><![CDATA[<p>After installing zshell and applying the zshrc from <a href="https://grml.org/zsh/" target="_blank">grml</a> system-wide, my man page doesn&#8217;t want to be colourful. The configuration is caused by a environmental variable GROFF_NO_SGR, when it&#8217;s set to 1, man page will be able to paint with colour.</p>
<p>Here is my personal .zshrc:</p>
<pre>
# Vim key binding
bindkey -v

# The important part.
export GROFF_NO_SGR=1

# PATH to current directory
export PATH=$PATH:.
</pre>
]]></content:encoded>
					
					<wfw:commentRss>https://luxing.im/applying-man-with-colour-under-zsh/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">293</post-id>	</item>
	</channel>
</rss>
