modified upload and download, and test it.