Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [dynamic-linking]

Dynamic linking is the process of resolving at runtime a program's external function calls or dependencies. It happens at program startup or even while the program is running, as opposed to static linking which is performed at compile time by the linker.

0
votes
0answers
38 views

Does Radare offer the ability to invoke the linker and disassemble a function (import or reloc)?

Sometimes I'm doing static analysis outside of the debugger, and I want to see what a function that a symbol points to will do after the linker does runtime relocation. All I see in the disassembly is ...
3
votes
1answer
305 views

Radare2 debugging - How to get into lazy imported functions?

I have a linux binary that imports functions from an external library (shared object). The functions are lazy loaded and not available when rip is at @main or @entry. When i step into such a function (...
2
votes
1answer
138 views

Macho - remove a LOAD COMMAND from iOS binary

I want to remove a LOAD_COMMAND from my iOS app binary. I tried jtool: jtool -rC 3 my_app_binary This worked when I was removing a dynamic library. But it generated an empty binary file and the ...
-1
votes
1answer
86 views

What is an “addend”?

From Learning Linux Binary Analysis by Ryan "elfmaster" O'Neill. On Page 32, the author states, The relocation records for 32-bit ELF files are the same as for 64-bit, but use 32-bit integers. The ...
0
votes
0answers
100 views

Set a Breakpoint in an executable type dynamic (ET_DYN)

I am trying to debug an executable marked as a shared object. I know the trick of run it in GDB and stop with CTRL+C, and other tricks from the question How to handle stripped binaries with GDB? No ...
3
votes
1answer
359 views

Resolve Addresses To Function Names

I have a malware sample that wraps LoadLibrary & GetProcAddress duo to dynamically resolve functions. After this wrapper is called the value stored in eax(which is the function name)immediately ...
1
vote
1answer
270 views

How can I resolve dynamic addresses (for APIs,DLLs etc.) to disassemble in IDA Pro?

I have memory dump of injected process. But the malware load libraries/functions dynamically and I need to resolve this. For example, If malware will use createThread, first get address of this ...
0
votes
3answers
745 views

Is it possible to call function in dynamic link library(.so) generated by Android JNI project?

I unzipped an apk file and got one libxx.so file. I find that there are some "exported"(but I guess the "fun" function is not exported by the original programer) functions in this library by IDA Pro, ...
1
vote
1answer
430 views

Could not find ld-linux-x86-64.so.2 in strace output

I did a ldd on /bin/cat and I see that dynamic loader library /lib64/ld-linux-x86-64.so.2 is a part of it. ldd /bin/cat linux-vdso.so.1 (0x00007ffe743f4000) libc.so.6 => /lib64/libc.so.6 (...
1
vote
3answers
295 views

How to locate dynamic instructions?

I am trying to make a game hack and there are a few instructions I need to get the addresses of to nop out. However, when looking at the instructions in Cheat Engine, they do not have a static offset ...
7
votes
1answer
3k views

How .reloc Section is used in PE file?

I have read document pecoff_v83 of Microsoft. In The .reloc section part, I have read: The Fix-Up Table contains entries for all fixups in the image. The Total Fix-Up Data Size in the Optional ...
1
vote
0answers
504 views

LD_PRELOAD in QEMU user space emulation

I was trying to emulate a firmware and as a part of the process I was interested in knowing what device files are being registered using mknod. In order to intercept those calls I had created a shared ...
1
vote
1answer
2k views

Dylib can run without code sign in iOS?

I learn from somewhere dylib should be signed in iOS, otherwise dyld will refuse to execute it. But when I test the example of this post. The dylib is not signed by default in this project, but it ...
1
vote
1answer
451 views

Dynamically v. Statically linked

I understand the difference between static and dynamic linking, but is it possible by using IDA Pro, Ollydbg, or any other reversing tools to determine if an executable was dynamically or statically ...
-1
votes
1answer
333 views

Hiding shared library calls from ltrace

I am trying to implement some antidebug methods. Although I have encrypted texts, ltrace reveals them, for example: strstr("Name:\tltrace\n", "ltrace") A solution would be static linking, but I do ...
2
votes
2answers
1k views

How the dynamic linker determines which routine to call on Linux?

I have a question about dynamic linking on Linux. Consider the following disassembly of an ARM binary. 8300 <printf@plt-0x40>: .... 8320: e28fc600 add ip, pc, #0, 12 8324: e28cca08 ...
0
votes
0answers
282 views

Intercepting syscall in a shared object (dynamically linked)

Ditto. Any technique that allows to intercept sys calls issued from a shared object file? At runtime, the shared object is dlopen'ed by main(). One candidate is to use static binary rewriting (e.g. ...
2
votes
1answer
191 views

How to recognize the function call in a dynamic lib?

when I disassemble an OpenCV dynamic library file (libopencv_imgproc.so), I find that there are a lot of bl instructions which target address are in the .plt section. But, I could'n find its symbol ...
0
votes
1answer
687 views

ldd doesn't show dynamic libraries

I'm trying understand how some parts of a closed source program distributed as a stripped binary implemented. When I run ldd on the program, it prints only 4-5 most basic C libraries as dynamic ...
1
vote
0answers
479 views

Define new code section in assembly code to compile ELF binary

I defined a new code section in my assembly program, which is going to be compiled into 32-bit ELF binary, on x86. I use the linker scripts to assign a specified address for this new code section, it ...
1
vote
1answer
405 views

How to load library defined symbols to a specified location?

The test is on Ubuntu 12.04, 32-bit, with gcc 4.6.3. Basically I am doing some binary manipulation work on ELF binaries, and what I have to do now is to assemble a assembly program and guarantee the ...
1
vote
0answers
170 views

Merging static library into mach-o executable

I got a mach-o executable and a static library that has a few __attribute__((constructor)) functions. Is there a (least painful) way to merge the static library into the mach-o executable ?
2
votes
1answer
249 views

How to re-use some asm code when GOT/GOT.PLT references involved?

Basically I am trying to re-use some asm code disassembled from a binary on x86 32bit Linux. I am facing some trouble when references of GOT/GOT.PLT involved like these. .... 804c460: 53 ...
5
votes
2answers
2k views

Rebuild symbol table

I would like to load a function I have decompiled in IDA Pro. All I have is the IDA Pro function name sub_xxxx() and obviously the address. I had thought about using dlopen to load the binary but ...
5
votes
2answers
4k views

How do I view external function calls in dynamically linked ELF binary in linux?

I used the file command in Linux to get information about a binary file. I am also looking for the addresses that these calls are located at. I think I can get this information from GDB or objdump but ...
3
votes
1answer
559 views

What does this call to CallWindowProc do?

I recently came across a script that would read a file into a string, then do the equivalent of CallWindowProc((pointer to string), (pointer to encrypted string), (length of encrypted string), 0, 0) ...
21
votes
1answer
18k views

What symbol tables stay after a strip In ELF format?

I am currently looking at the ELF format, and especially at stripped ELF executable program files. I know that, when stripped, the symbol table is removed, but some information are always needed to ...
20
votes
3answers
8k views

Can I statically link (not import) the Windows system DLLs?

I have compiled following C source code in VS2010 console project. #include <stdio.h> int main(int argc, char* argv[]){ printf("hello world\n"); return 0; } then I used /MT option for ...
7
votes
2answers
4k views

Base address of shared objects from ldd output

I'm on a Linux machine with ASLR disabled. Running ldd on a binary gives me the following result : linux-gate.so.1 => (0xb7fe1000) libc.so.6 => /lib/i386-linux-gnu/libc.so.6 (0xb7e5c000) /lib/...