Here's an idea off the top of my head - no idea if it's a good one - hasn't been baking long enough :-)
One of the extensions that can be built into PHP is called cURL (see the list of functions in the manual). With it, you can have one server build arbitrarily complex requests to send to another server, and get back results.
My idea is an extension of Metin Arman's.
I need names. I'm going to call the server that wants the file "NEEDY" and the server that is being asked for the file "MINE". Why? I just can, that's all.
Okay, so NEEDY (with cURL installed) sends a request to MINE. The request consists of form POST data containing login request stuff. Notice that there doesn't need to be any communication between NEEDY and MINE before this.
When MINE receives a request, it looks for the login data, and checks it off against its database, to see if it is a valid login. If it is a valid login, it sends back the wanted file. Otherwise it just sends back a blank page or a denial message.
Since this is a form POST and since it doesn't have to be entered by a human, the login data can be quite big and complicated (say, three kilobytes of random ASCII), defeating dictionary-type attacks, and nasty people are reduced to snooping your network connection or breaking into one of the servers.
For added security, you could have MINE send back a countersign that NEEDY has to respond to (with another cURL request) in the right way before MINE will serve up; this will defeat those who just snoop your network conection, because even if they know the initial login request, that doesn't mean they can predict what needs to be sent in response to the countersign (which would be different each time). They'd then be having to either snoop for a very long time and try and discover a pattern, or again break into the server directly.
Now there is just the matter of network snoopers getting MINE's file from the network connection, but there're plenty of opportunities for encryption if you want it.
There y'go. How's that for a half-baked idea?