How does a program like IDM (internet download manager) work?

7

4

By this I do not mean that it opens multiple connections. I am more interested in how it monitors the browser's activity and recognizes when a file is available for download (a music file, or a video, or whatever).

Is this something that it adds to the browser? Is it somehow scanning all traffic that is going to the PC? Is it acting as a kind of proxy?

soandos

Posted 2011-08-16T22:30:40.897

Reputation: 22 744

Connect to remote location, read list of files, compare timestamp / checksum / etc. of the files, then do whatever is specified based on that info... notify, download, etc. – Joe Internet – 2011-08-16T22:59:27.870

I don't follow. I dont connect to any remote locations, what list of files, checksum??? – soandos – 2011-08-16T23:01:50.923

Questions on Super User are expected to be based on actual problems that you experience; in this case you could simply read their manual as they explain it to you. In cases where they don't explain it to you, you should ask it to the owner of the product as he is the one who is most likely to know this and he should be able to explain it to you. It simply interacts with your browser, where it is told when a download has been requested. If you are afraid, either don't use an unnecessary download manager at all or get yourself a good scanner/firewall... :)

– Tamara Wijsman – 2011-08-17T22:50:27.460

3I do not have a trust issue with IDM (though if I did that would be a an actual issue I face). To quote from the FAQ: "However, if your motivation is “I would like others to explain ______ to me”, then you are probably OK." So I think my question is ok. I want to know how it monitors the browser, so It simply interacts with your browser" does not help me. IDM does not say how it works. – soandos – 2011-08-17T22:59:21.720

Reverse engineering is off-topic here; we can't tell you the inner workings of a closed source program, that would be illegal. The best you can do is as said reading their documentation or contacting there support, there is not much more that we can say than "it simply interacts with your browser by monitoring it or through an add-on, it kicks in when you perform a download". What are you actually trying to do? I would like others to explain _ to me is no exception, you still have no problem that you need explained. We can't help you if you don't have an actual problem... – Tamara Wijsman – 2011-08-17T23:07:48.587

3

I don't want to create a duplicate program. I want to know roughly how it works (see question). I don't see this as so unreasonable as there are a very limited number of ways to do this. I want to solve my other question elegantly (see here) but in a specific case (not by uninstalling IDM thought).

– soandos – 2011-08-17T23:17:45.543

2@Tom - "intellectual curiosity" is a legitimate cause for questions. He didn't ask to know exactly how is the code, he only wonders how is that possible, how such program can do that, like plenty of other questions on the site. It's not "what exactly IDM uses to do that", just a curiosity about download managers as a whole. Seems legitimate to me. – Gnoupi – 2011-08-21T11:09:26.597

Answers

4

There are basically two mechanisms, which depend on whether the IDM-like product installs itself in the operating system or only inside the browser.

In the case where it installs as a full-fledged product through the operating system, then in Windows for example it sets system-wide hooks, the same mechanism that is used by firewalls and anti-virus products, for monitoring network activity from the Internet. For Windows this is described as :

A hook is a mechanism by which an application can intercept events, such as messages, mouse actions, and keystrokes. A function that intercepts a particular type of event is known as a hook procedure. A hook procedure can act on each event it receives, and then modify or discard the event.

In the case that it is installed only in the browser, it uses the same mechanism as used by Greasemonkey for doing Javascript Injection. This requires an add-on/plugin to be installed into the browser, that will scan incoming HTML for downloadable items, and either list them on the side (normally on the browser's status bar), or modify the HTML itself to include a "Download" button near the downloadable element.

harrymc

Posted 2011-08-16T22:30:40.897

Reputation: 306 093

1So why does it need a firefox add-on, but no add on required for chrome, IE? – soandos – 2011-12-01T15:11:05.780

If we are talking about this IDM, then I see that has an .exe installer. This means that it is installed outside of the browser and so can use system hooks without need for a plugin.

– harrymc – 2011-12-01T15:39:47.410

So why does it give one for firefox? – soandos – 2011-12-01T20:35:30.220

Probably for better integration within the browser, for example using the status bar (just guessing - I don't use IDM). They probably haven't gotten around yet to doing the same for other browsers (or decided not to). – harrymc – 2011-12-01T21:07:34.967

I'd like to note here, that I have built a download manager years ago. And that most Download Managers do have plugins for IE. Mostly ActiveX plugins. – uSeRnAmEhAhAhAhAhA – 2014-03-27T13:08:01.500