Search code examples
linuxreverse-engineeringdynamic-linkingghidra

What is undefined function when I use Ghidra to dissemble a .so file?


I am now trying to dissemble a .so file and I found a strange part :

enter image description here

And follow FUN_004d9f38 lead me to this :

enter image description here

Can any one help me understanding what is so called undefined __cdecl FUN_004d9f38(void), specifically what is a undefinde function.

As the code show above. the first picture's code use a jump instruction jump into FUN_004d9f38, but the FUN_004d9f38 is a invalid instruction code of 67. How can the program manage to still work properly ?


Solution

  • undefined is a special data type, that Ghidra uses to to mark locations where the type is not known/defined yet. If you right click the function name and Edit Function you should see a window like this that makes this clearer:

    enter image description here

    if you change the datatype in the list to e.g. qword you get qword FUN_1000081e0 instead of undefined FUN_1000081e0:

    enter image description here