ifl
[martlubbers.net.git] / archive / nsa-dropbox.html
1 <html>
2 <head>
3 <title>Use any untrusted cloud storage with encryption</title>
4 <link href="style.css" rel="stylesheet" type="text/css">
5 </head>
6 <body>
7 <h3>PREREQUISITES</h3>
8 Install encfs and fuse<br />
9 <pre># apt-get install fuse encfs</pre>
10 Install a cloud service(copy.com used here)(assuming ~/bin is in your path and running on a 64bits machine)<br />
11 When using a different architecture just change x86_64 to x86 or armv6h in the client install script<br />
12 If ~/bin is not in your path add to your bashrc(example using user: test):
13 <pre>PATH=$PATH:/home/test/bin</pre>
14 Download and install the copy client for linux
15 <pre>
16 $ wget https://copy.com/install/linux/Copy.tgz
17 $ mkdir ~/bin/copy; tar -xf Copy.tgz -C ~/bin/copy
18 $ ln -s ~/bin/copy/x86_64/CopyConsole ~/bin/CopyConsole
19 </pre>
20 <h3>SETUP</h3>
21 <p>Make sure your user is in the fuse group and setup the encfs share by doing this:
22 <pre>
23 $ mkdir ~/.copy.encr ~/copy
24 $ encfs ~/.copy.encr ~/copy
25 </pre>
26 When they ask use option p for paranoia and pick a password.<br />
27 Create an account on copy.com and setup the client by typing this command
28 <pre>$ CopyConsole -u=the_mail_you_signed_up_with -r=/home/your_linux_username/.copy.encr -p=the_password_you_signed_up_with</pre>
29 This creates a setup that does this automatically in the future<br />
30 Let the daemon and the encfs autostart when you and only you are logged in by adding this to ~/.bashrc
31 <pre>
32 if ! mountpoint -q ~/copy; then
33 encfs ~/.copy.encr ~/copy
34 fi
35 if ! pidof CopyConsole >> /dev/null; then
36 CopyConsole -daemon 2>&1 1>/dev/null
37 fi
38 </pre>
39 Congratulations your setup is working. <br />
40 When you want to stop the daemon you can kill the pid given by ~/.copy.pid.<br />
41 From now on your computer or server will ask one time for you password when the first bash starts in your account.</p>
42
43 <h3>NOTES</h3>
44 <p>This could work with any cloud service, just mount the folder it wil sync first with encfs</p>
45 </body>
46 </html>