second implementation of file-sharing