SFTP: add file_exists, is_dir and is_file functions

also expand caching layer