LDAP

I set up an LDAP server to manage my email login password. I then promptly forgot how I set it up. This is the story of how I recovered it, mostly for my personal future use.

Bug fix for FastRI

I recently installed FastRI to speed up retrieving Ruby documentation. Following the directions on the website, I installed it from the source tarball rather than as a rubygem. Then, when I tried it, I received this error: sbf5:~/fastri-0.3.1> qri /usr/lib/ruby/1.8/rdoc/ri/ri_paths.rb:61: uninitialized constant Gem::Version (NameError) from /usr/lib/ruby/1.8/rdoc/ri/ri_paths.rb:57:in `each’ from /usr/lib/ruby/1.8/rdoc/ri/ri_paths.rb:57 from /usr/local/lib/site_ruby/1.8/fastri/util.rb:38:in `require’ from /usr/local/lib/site_ruby/1.8/fastri/util.rb:38 from …

Produce entropy for /dev/random in Linux

I was generating GnuPG keys, and got the following message: Not enough random bytes available. Please do some other work to give the OS a chance to collect more entropy! (Need 274 more bytes) We need to generate a lot of random bytes. It is a good idea to perform some other action (type on …

User Home Directories in Nginx, Part 3

I recently upgraded to the newest version of Nginx, and discovered that the technique I described in my previous two posts no longer works. The good news is that it no longer works because some of the bugs in Nginx were fixed, and the reason I needed that complicated workaround solution was because of bugs …

Autoloading Classes when Deserializing YAML Objects (or, What Is This YAML::Object?)

Rails will automatically load Ruby files from your /app, /lib, and other directories when you use the appropriately named constant. For example, if you use the name RailsExampleObject in your code, Rails will automatically look for a file called rails_example_object.rb and load it. However, this autoloading of classes fails when deserializing objects from YAML. This …

Fun with XeTeX and Fonts

XeTeX is an improvement upon the famous typesetting system TeX. XeTeX provides Unicode support and native support for standard fonts. Unfortunately, XeTeX is fairly poorly documented. Here are some interesting findings I have come across (some particular to XeTeX, others just general ideas for TeX and LaTeX).

Encrypting Files with openssl

Here is how to encrypt and decrypt files using public-key encryption and openssl. I prefer this over GPG because openssl is installed everywhere (including OS X by default) and it requires no specialized subsystem (keyrings, etc.). Just two key files and the document to be encrypted.