Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

referenced DLLs as seen in Dependency Walker

Posted on 2013-02-03
4
Medium Priority
?
428 Views
Last Modified: 2013-03-25
Hi, I have a bunch of DLLs referenced in my application, but when I view the application in Dependency Walker I do not see those DLLs, I only see the system DLLs, How does this work, thanks!
0
Comment
Question by:Mydeen Yussouf
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 44

Expert Comment

by:AndyAinscow
ID: 38851461
Does your app actually call any functions in those dll's ?  (Does it compile and run if you remove the dependancy?)
0
 
LVL 31

Accepted Solution

by:
Zoppo earned 375 total points
ID: 38851493
Hi olmuser,

there are two ways to use a DLL:

1. DLL is implicitely linked to the EXE: when the executable is created the linker adds functionality which loads a needed DLL if it's not yet loaded and replaces some kind of dummy functions with the functions loaded from the DLL. In this case the list of needed DLLs is stored in the binary. These can be shown by DependencyWalker.

2. Explicit use: the executable loads DLLs at runtime using LoadLibrary and accesses function with GetProcAddress. In this case there's usually no info available in the binary which DependencyWalker can use to determine the dependencies. (I say usually because it might be possible for DependencyWalker to find places like i.e. LoadLibrary( "user32.dll" ), but at least when i.e. all DLLs within a given directory are loaded iterating through the files per code this won't be possible).

Hope that helps,

ZOPPO
0
 
LVL 86

Expert Comment

by:jkr
ID: 38851506
I'm with Zoppo here. You can find out about that easily if you choose 'Profile...' from the Dependency Walker's main menu, it will show all DLL load events. Oh, and one thing to add to what Zoppo wrote: There's also a '3.' which applies to COM DLLs - these are also loaded via 'LoadLibrary()' after the sever DLL is found via a registry lookup.
0
 
LVL 64

Assisted Solution

by:btan
btan earned 375 total points
ID: 38853422
Below can be helpful for understanding especially for dynamic loading and system hooks, it needs runtime profiling. So you can try using Application Profiling to Detect Dynamic Dependencies

http://www.dependencywalker.com/help/html/application_profiling.htm

When a module is first opened by Dependency Walker, it is immediately scanned for all implicit, delay-load, and forwarded dependencies. Once all the modules have been scanned, the results are displayed. In addition to these known dependencies, modules are free to load other modules at run-time without any prior warning to the operating system. These types of dependencies are known as dynamic or explicit dependencies. There is really no way to detect dynamic dependencies without actually running the application and watching it to see what modules it loads at run-time. This is exactly what Dependency Walker's application profiling.

It is the job of the user to "exercise" the application to ensure that all dynamic dependencies are found. Usually dynamic dependencies are only loaded when needed.needed. For example, modules related to printing might only be loaded if the application actually prints. In a case like this, if the application does not perform a print while being profiled, then Dependency Walker will not detect those modules related to printing. Other modules might only get loaded if an error occurs in the application. Scenarios like these might be hard to produce. Because of this, It is impossible to guarantee that all dynamic dependencies are found, but the more an application is exercised, the better the odds are of finding them.

The faq is useful reference
http://www.dependencywalker.com/faq.html

You may be interested to look at Process Explorer
http://www.symantec.com/connect/blogs/using-process-explorer-who-loaded-dll
0

Featured Post

NFR key for Veeam Agent for Linux

Veeam is happy to provide a free NFR license for one year.  It allows for the non‑production use and valid for five workstations and two servers. Veeam Agent for Linux is a simple backup tool for your Linux installations, both on‑premises and in the public cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

As with any other System Center product, the installation for the Authoring Tool can be quite a pain sometimes. This article serves to help you avoid making these mistakes and hopefully save you a ton of time on troubleshooting :)  Step 1: Make sur…
Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
In this video, we discuss why the need for additional vertical screen space has become more important in recent years, namely, due to the transition in the marketplace of 4x3 computer screens to 16x9 and 16x10 screens (so-called widescreen format). …
The viewer will learn how to simulate a series of coin tosses with the rand() function and learn how to make these “tosses” depend on a predetermined probability. Flipping Coins in Excel: Enter =RAND() into cell A2: Recalculate the random variable…

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question