If you work on remotely connected machines, most likely you’re going to use SSH to secure your connections. But, what if you just want to work with files on a remote server, but find SSH file transfer tedious in repetition and establishing a VPN tunnel is too complicated?
What you’re looking for is a simple tool for mounting remote file systems easily, transparently and securely as if they were just another part of your local machine. In this hack, we’ll show you how to configure Fuse and SSHFS to access remote file systems securely over SSH.
Fuse (File system in User-space) is a Linux kernel module that allows non-privileged users to create their own file systems without modifying the kernel. Fuse provides a bridge between user-space file system code and the actual kernel interface. SSH File System (SSHFS) is a file system client based on the Secure Shell protocol.
Step 1: Installing Fuse
If you don’t already have Fuse installed, grab the latest tarball from their web site. As of writing, the most current stable release available is 2.6.5. Open the tarball file and install Fuse by running the following commands:
# tar -xzf fuse-2.6.5.tar.gz
# cd fuse-2.6.5
# ./configure
# make && make install
After FUSE has finished building and you have installed it, we can move onto installing SSHFS.
Step 2: Install SSHFS
SSHFS works with FUSE to mount drivers over SSH. You can download the latest build from here. As of writing, the current stable release available is 1.8. Install it using the following commands:
# tar -xzf sshfs-fuse-1.8.tar.gz
# cd sshfs-fuse-1.8
# ./configure
# make && make install
Step 3: Mount your remote file system
Now that you have a working setup, you need to create a new mount point and mount the remote server file system using the SSHFS command. If everything goes well, the remote file system will be available as a regular mount file system.
# mkdir /mnt/myremotefs
# sshfs user@remote_server : /mnt/myremotefs
# cd /mnt/myremotefs
# ls
As you can see, SSHFS is a powerful tool for sharing files across the Internet. Not only does it provide security, but it also provides a simple method accessing a remote host and its file systems.
Post a Comment
Contact
Have a hot hack? want to request a hack? let us know - editor [at] security-hacks.com
subscribe
Search
Latest Entries
- msramdmp: Dump RAM from a USB stick
- SWFIntruder: Are your Flash applications secure?
- Untidy: Python-based XML fuzzer
- Jailbreaking iPhone software v1.1.1
- Secure browsing with Squid and SSH
- Combat spam with Gmail aliases
- 5 Essential laptop security tips
- Email encryption with GPG and Mail.app
- Firefox: Disable suspicious JavaScript features
- aSSL: Add SSL to your Ajax application
Archives
