Title: Dimke Web2Mail
Picture: Web2Mail
Explanation: Web2Mail contacts to a webserver of your choice and checks if a certain document has changed since the last check using the HTTP HEAD command. If so, it will load this file and send it to a list of amail addresses.
This allows to get informed about documents even if they are locked out by some kind of firewall, for instance, due to censorship. If you use a SecureSocketLayer / Https encrypted connection to access your emailbox then nobody can see the information you get and even doesn't see the filename of your data.
It is important to mention that there is no big data transfer to evaluate if the desired file has changed due to the Http HEAD command, which causes only about one or two hundred bytes to be tranferred, rather than downloading the whole file using the GET command.
How it works: Dimke Web2Mail is completely written in Perl for Unix and is based on the legendary LWP library which allows to communicate with any kind of webservers.
It is, or at least, it should be started from the Unix crontab, and first uses the Http HEAD command to check the "last modified" entry sent by a webserver as a response to the HEAD query. This information is written to a file and Web2Mail compares this information every time it sends a query to the webserver.
In the case the file had been modified in the meantime Web2Mail loads this file using the Http GET command, frees it from any unnecessary html information and sends it as a plain text email to a list of recipients. The user agent that shows up in the logfile of the machine you get the desired file from will be the same for the Http HEAD query and for downloading via Http GET command.
Also, no recipient sees any of the other email addresses because Web2Mail does not make use of the email to: field, but rather uses the email bcc: field only.

New in the most recent version, Dimke Web2Mail V1.0:
You will be announced about any kind of failure if you have no access to the web object you want the script to get for you. If, for instance, someone blocks HTTP HEAD in the firewall, or, the server is completely down, then the current version of Dimke Web2Mail will no longer send an empty message to everyone whose email address is in the list, but instead Dimke Web2Mail will print the failure reason which then will be sent to you via email by the cron process.
This is very convenient and drastically increases transparency.
How to use: First, get the zipped package, unzip it and transmit it to your server. It is recommended to mkdir a new directory, which is not accessible from any webserver process which eventually runs on the same machine to prevent hacking attacks. Do a chmod u+x web2mail.pl on the command line to make it executable. Be sure that the LWP library is installed because Web2Mail makes heavily use of the classes defined within this object oriented library. If it is not present then contact your system administrator or install it yourself.
Then edit the bcc.txt file as well as the main program file web2mail.pl where you should define which file you want to get.
Then verify that everything is set up correctly by manually modifying or deleting the headinfo.txt file and start Web2Mail by hand typing ./web2mail.pl on the command line in the directory where you had put the files contained in the package.
If this works then edit your crontab so that Web2Mail will be executed automatically. Just type crontab -e on the command line and add the following or a similar line - the following example shows how to define a cron job which will start Web2Mail once per hour beginning at 6:01 in the morning and ending at 6:01 in the evening from Monday to Friday:
1 6-18 * * 1-5 /full/path/to/web2mail/web2mail.pl 2>&1 >/dev/null
Be sure to have your email address set up correctly in your crontab to get informed about failure due to absence of the target system, i.e., HTTP GET fails, or HTTP HEAD fails if someone blocks it in the firewall.
Download package: web2mail.zip
[Developer Root] [Main Page]