Archive for the 'How To' Category

Ars Technica covered a very nice detailed how-to to install SSL/TLS cert from StartSSL in OSX server. I shall not rehashed their steps to obtain the certificate. For me, I am keen to use StartSSL’s free Class 1 cert with Nginx server and it is not covered in their help/support pages.


Notes on Generating CSR

Assuming your server private key is server.key and you are inside the directory storing the key. The Openssl command will look something like this:

openssl req -new -key server.key -out server.csr

As you key in the necessary fields for your CSR, you MUST OMIT the EMAIL ADDRESS field. ie. LEAVE it BLANK & press ENTER.

Otherwise, when you request the certificate at StartSSL, you will end up making a Class 2 certificate request which require validation of email and it will cost you money.


Installing the Cert in Nginx

Let’s say everything went smoothly, after pasting the CSR into the webpage and clicking continue, you will see the Certificate contents in the webpage. There is a link to CLASS 1 CA Intermediate cert file. You must download that file into your server.

In order for Nginx to use the free cert, you have bundle the Intermediate CA cert and the new cert together into a single file:

cat class1.ca.pem newcert.pem > bundleforyrdomain.pem

The naming of each file will differ from your server but the ORDER is IMPORTANT! The CA Intermediate file must first in new file. After which, adjust your existing nginx.conf, restart nginx should NOT yield any error. Your new free cert is in!

Related posts:

    http://granturing.blogspot.com/

    http://www.ehomeupgrade.com/…how-to-boot-windows-xp-off-a-compact-flash-card/

    Inspired by the two articles above, I decided to share my own experience building a XP PC running off Compact Flash.

    Granturing’s blog covers the use of Enhanced Write Filter in Windows XP. EWF is a driver that write-protects the CF card when XP is running. Effectively, whatever changes you make to the XP after EWF is enabled will be undone upon reboot.

    Will’s entry details cloning of a harddisk XP installation into a CF card. It is a good way particularly if you want a lean copy of XP.

    My approach is a short-cut by directly installing XP into the CF and using EWF to make XP almost read-only.

    Stuff you need

    XP CD
    The same stuff for any typical XP installation.

    A typical Intel-based PC
    May be an old PC or something that you want to experiment with…

    CF-to-IDE + CF card

    3.5” adaptor I bought off Ebay and a speedy 4GB Sandisk Extreme III from a local shop.


    You may also consider the above adaptor (click image) from Amazon as it has some positive reviews.

    Overview

    1. Install CF + adaptor (remember the power cable)
    2. Boot with XP CD & install as per normal
    3. Turn off XP paging (Virtual Memory setting) & restore point (if any)
    4. Install any other applications & drivers into the XP
    5. Install & enable EWF

    First 4 steps are straight forward, I shall not go into those steps. I will elaborate step 5.

    Install & enable EWF

    It is amazing that you need only 3 files, well 4 files including the registry settings (thanks to Granturing) to get EWF working. Click here to download & save registry file (somewhere).

    Registry Settings
    Open the registry file with text editor and take a look at the last portion:

    [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ewf\Parameters\Protected\Volume0]
    “Type”=dword:00000001
    “ArcName”=”multi(0)disk(0)rdisk(0)partition(1)

    It is important to get ArcName right.

    Go to the boot drive of the TARGET MACHINE WITH XP INSTALLED INTO CF CARD and open up “boot.ini” . The “multi…” string (highlighted) should be the same and look something like:

    default=multi(0)disk(0)rdisk(0)partition(1)\WINDOWS

    If you can’t see boot.ini, it is likely your explorer is hiding system files. Use explorer’s Folder Option to show hidden and system files.

    Copy EWF driver files
    To obtain the 3 EWF files: ewf.sys (driver), ewfmgr.exe (command program to control the driver) & ewfntldr (NT loader), download XP Embedded SP2 Feature Pack 2007 ISO file

    - Extract (or browse) into “rep” subfolder with your favorite tool (eg. WinRAR)
    - The 3 EWF files are in “rep” subfolder

    We assume now you are in your XP that is running off the CF, with paging and restore point turned off (mine did not have restore point tab) nicely.

    Copy the 4 EWF files into the respective destination locationsof the XP running off CF:

    ewfntldr         – Backup original ntldr eg C:\ntldr.bak, rename ewfntldr to ntldr
    ewf.sys          – Copy to your windows SYSTEM32\DRIVERS
    ewfmgr.exe    – Copy to your windows directory
    ewf.reg           – Anywhere at the target machine

    PLEASE MAKE SURE YOU COPY EWF.SYS INTO THE RIGHT PLACE!

    I screwed my first installation because I copied the driver file into SYSTEM32 instead of the sub-folder “drivers”. Looking back, I could have use a multi-card reader on another machine to fix it…

    Merging Registry Values

    Before merging the registry settings downloaded earlier, please check that:
    -    ArcName is assigned correctly
    -    Permission is set to Full using Regedit (Start -> Run…)
    For HKEY_Local_machine\System\CurrentControlSet\Enum\Root

    Once enabled Full for Everyone, double click the registry file to merge.

    Cross your fingers, reboot…

    Then again, we will not see XPs very soon on fresh desktops but on UMPCs, at least for a while.

    For more info, visit:
    http://granturing.blogspot.com/2007/12/this-guide-is-based-off-my-original-ewf.html

    Related posts:

      Free boob job... Well not exactly free because Photoshop is NOT free…

       

      Related posts:
        Clicky Web Analytics