how to find the address of a function in a c++ program : <p>i need to find the address of func in the stack so that if i provided a 32 long "A" string and then the function address in the stack i would get the Access granted </p>

<p>i remember i did it using <code>objdump</code> but i can't seem to figure it out </p>

<pre><code>#include &lt;iostream&gt;

using namespace std;


void func() 
{ 
     cout &lt;&lt; "Access Granted \n";


}

int main()
{
    char buff[20];

    cin &gt;&gt; buff;
    cout &lt;&lt; buff;

    return 0;
}
</code></pre>

<p>i tried immunity debugger but i was not successful </p>
