better file size check, support for uploading files from http protocols