Jump to content

Setting up a proxy-server to bypass mimetype blocking


Recommended Posts

Hey there.

I'm sitting behind a firewall with an ISA-server which denies downloading of almost all filetypes.  I can understand why they've blocked downloading of executive files like MSI and EXE, but often I want to download PSD, AI, TIFF and RAR - and I do not want to go down to the IT-department to make them do it for me.

That's why I thought, isn't it possible to set up a site which acts like a proxy and downloads the files then renames them/changes the mimetype to an allowed type like the ones DOC, TXT, ZIP have or something like that?

Do anyone of you know of a way I could this with a server-side language like PHP?

Thanks :)

Edit: Should this post maybe have been put under the "Hacks, Mods & Coding" forum? If so - my bad.

Link to comment
Share on other sites

Of course I could do it with a SSH-client, but I'm just thinking wild here.

Some things I'm curious about:

1. When I download a file, where is the info about mime-type stored, and is it possible for a webengine (PHP) to change it?

2. Can I create a serverside application that downloads from an external site into a buffer (so I can manipulate the info some how). Then sends this out (so I would get a download-dialog) to my client.

Link to comment
Share on other sites

Most places allow real zip file downloads. Just throw it in a zip and then download it. You can put rar files in a zip archive. If you have your own server utside th enetwork, I am sure you could pass it a url to a file and have php zip it up for you and you could then download it.


Now, I am no programmer, so getting it to work is on you, but I think it could be done.

Your server with php outside of network firewall > pass it url to file you want > server gets file and zips it > stores it on server > creates link to archive for you to download from your server

Link to comment
Share on other sites

That would solve my problem, haven't thought of that solution myself.

Thanks, I'll look into it :)

But, I am fairly competent with PHP, but could anyone give me a pointer on how to download files from other sites?

You could use sockets and connect on port 80 to the server and then issue your requests and stuff straight to the HTTP server.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...