client: Add ability to register files

Files can now be registered. During registration, a file's SHA1 hash is
calculated and it is added to the local map of known files.