In order to successfully implement a patch, we need to understand the PE file format (PE stands for portable executable). While a detailed specification may be obtained at this URL, http://www.microsoft.com/whdc/system/platform/firmware/PECOFF.mspx, we only need to understand a few things about the format and be able to manually parse its basic structure.