# Simple Fileshare

A very simple -- and insecure -- CGI script for sharing files via links.

The script allows anyone with access to upload any file. The following security measures should be implemented before releasing this into the wild:

* Limit access to this script to only people you trust.
* Set a size limit for uploads in your web server config.
* Implement some sort of control mechanism to ensure that your disk does not fill up with files. A cron job that removes old files, or even an isolated partition where the files live.
* If you follow the installation instructions below then make sure nobody can access the .git directory.

## Installation

Clone this repository into the folder you wish to have it. Take note of the security considerations above and implement necessary mitigations.

Check out a local branch:
`git checkout -b local`

Change the `FILES_DIR_URL = "https://yourdomainhere/simple-fileshare/files"` to something suitable for your site.

## Upgrade

I gotta say I don't believe there will be any, but still.

```
git checkout master
git pull
git checkout -
git rebase master
```

That should be it.

