title: Show info about IMAGE_EXPORT_DIRECTORY
body: <p>I want to print information about <code>IMAGE_EXPORT_DIRECTORY</code> in the following form:</p>
  
  <pre><code>&lt;Name1&gt;,&lt;Ordinal1&gt;,&lt;FileAddress1&gt;
  </code></pre>
  
  <p>I know that this IMAGE consists of 3 arrays:</p>
  
  <ol>
  <li>AddressOfFunctions - (Export address table, each element is an RVA)</li>
  <li>AddressOfNames - (Export Name Pointer table, also each element is an RVA - ordered ?)</li>
  <li>AddressOfNameOrdinals (where the element of the array - Base represents an ordinal in the EAT)</li>
  </ol>
  
  <p>But how can i access those tables in order to print information for each element in one line? Also, what would happen when NumberOfNames &lt; NumberOfFunctions ?</p>
  
  <p>I already know how to get to the IMAGE_EXPORT_DIRECTORY</p>
  
  <pre><code>PIMAGE_DATA_DIRECTORY pFirstDir = &amp;(pOptionalHeader-&gt;DataDirectory[IMAGE_DIRECTORY_ENTRY_EXPORT]);
  if (pFirstDir-&gt;Size &gt; 0)
  {
          PIMAGE_EXPORT_DIRECTORY pExportDir = (PIMAGE_EXPORT_DIRECTORY)((BYTE *)pDosHeader + ConvertRvaToOffset(pFirstDir-&gt;VirtualAddress, pNTHeaders));
  }
  </code></pre>
  
  <p>If someone could explain how those arrays actually work  or an algorithm of how to access them it would be greatly appreciated.</p>