title: Why are .dynsym entries in ELF64 executable uninitialized?
body: <p>I have an <code>x86-64</code> executable and I am trying to analyze it using static methods. Starting from <code>_start</code>, I see a jump to <code>0x400648</code> - an address within the <code>PLT</code> - which contains the instruction <code>jmp *0x20065a(%rip)</code>. This jump leads to <code>*0x600ca8</code>, which is actually <code>0x40064e</code>. This brings us back to the <code>PLT</code> and executes <code>pushq $0x2</code>.</p>
  
  <p>Here's where I'm stuck: I know the <code>pushq $0x2</code> instruction exists to tell the dynamic linker to resolve the 3rd entry in the <code>.dynsym</code> table. The problem is that the <code>st_value</code> field in that entry is <code>0x0</code>. This value should actually be the offset of <code>main</code> from <code>_start</code>, right? If so, how does the <code>st_value</code> field get initialized?</p>