Is there any way for a consumer to enumerate all interfaces implemented by a given COM object?
Dependency Walker might do the job for you...
http://theircorp.byethost11.com/index.php?vw=TypeLib is a free tool to examine the TBL files.
Dependency Walker won't show the interfaces as the only exports are DllGetClassObject, DllRegisterServer, etc (for DLL-hosted COM).
You may, as weismat says, inspect the TLB files. Many COM objects contain embedded typelibs in the resource section of the executable. With a tool such as resource hacker you can extract the TLBs and use LoadTypeLib COM functions to get a pointer to ITypeLib interface (you could use LoadTypeLib/LoadTypeLibEx directly with a COM or EXE DLL, of course).
WIth this interface you can iterate over the types contained within.
You can try IDispatch/IDispatchEx if you simply want to know what methods are callable from your consumer.
In COM, the QueryInterface method on IUnknown is not required to expose what interfaces it may return. You ask for one based on its IID and you either get it or not. The implementation of QI in a particular COM object varies considerably although it's supposed to follow the pattern described by Microsoft here - http://msdn.microsoft.com/en-us/library/ms682521%28VS.85%29.aspx.