What are most reasonable/secure offsite backup services? reddit / BSD ---------------------------------------------------------------------- pentag0 · 2014-08-21 04:44 I'm looking into defining the backup strategy for my VPS files/databases and was curios to learn who uses what as a backup destination. I need small, secure app to do it. Are there any decent CLI clients for popular free storage services apart from Dropbox? Maybe GoogleDrive, to be triggered via cronjob nightly. ---------------------------------------------------------------------- brynet · 2014-08-21 05:29 Tarsnap is fairly popular in the BSD community, it was written by a FreeBSD developer. ---------------------------------------------------------------------- pentag0 · 2014-08-21 05:50 Yeah, I've heard about that but it isn't free even though it looks cheap. I don't think I need a paid solution when i have 15 gigs of storage in Google Drive. Plus paid plans are insanely cheap. Like 100GB for $5/mo or so. ---------------------------------------------------------------------- [deleted] · 2014-08-21 11:07 Google is able to cut costs because 1) they are using the information you store to sell advertising, 2) they're not encrypting the data so they can do deduplication across all users. ---------------------------------------------------------------------- godlesspeon · 2014-08-21 11:23 I'm using Amazon S3. I do a tarball, gzip it then run it through openSSL AES256 then push it to S3 daily. Upload to S3: http://tmont.com/blargh/2014/1/uploading-to-s3-in-bash Encrypt: openssl enc -aes-256-cbc -salt -in file.tgz -out file.tgz.enc -k PASS Decrypt: openssl enc -aes-256-cbc -d -in file.txt.enc -out file.txt -k PASS Like tarsnap but cheaper and you can swap the back end out for another cloudy outfit. Costs about $2-3/month for my data volume and transfer (not huge) ---------------------------------------------------------------------- Freeky · 2014-08-21 14:18 [Cyphertite](https://www.cyphertite.com/) offer 8GB for free, unlimited storage for $10/month, and provide client source. ---------------------------------------------------------------------- pentag0 · 2014-08-21 14:33 Sounds really interesting.Well give it a try. Thanks mate! ---------------------------------------------------------------------- ewood87 · 2014-08-21 16:00 I used [Duplicati](http://www.duplicati.com/) for a while to backup to my Rackspace Cloud Files account. They explicitly support S3, Cloud Files, Google Drive and Skydrive but it would also work with any provider that allows WebDAV access. They don't have FreeBSD listed as supported but I think it used mono on the non-windows platforms which means it might work if you could get mono installed on your VPS. ---------------------------------------------------------------------- pentag0 · 2014-08-21 16:03 I dint think there's possibility of installing stuff like mono on production server. ---------------------------------------------------------------------- Freeky · 2014-08-21 16:38 I wouldn't use `openssl enc` having looked at it - it's looks more like a crappy example of the API than a suitable serious encryption tool. The most obviously awful bit: if (!EVP_BytesToKey(cipher,dgst,sptr, (unsigned char *)str, strlen(str),1,key,iv)) That hardcoded `1` near the end is the iteration count to the ([obsolete](https://www.openssl.org/docs/crypto/EVP_BytesToKey.html)) key derivation function, which is what turns your passphrase into an encryption key (using MD5, by default). Quoth RFC2898, 14 years ago: > For the methods in this document, a minimum of 1000 iterations is recommended. For perspective, the old Xeon in my home server can pump out over 5 million MD5's per second per core. The old GPUs gathering dust on the shelf next to it can pump out over 5 *billion* per second, each. I tend to use [scrypt](https://www.tarsnap.com/scrypt.html) for this sort of thing: > On modern hardware and with default parameters, the cost of cracking the password on a file encrypted by scrypt enc is approximately 100 billion times more than the cost of cracking the same password on a file encrypted by openssl enc; this means that a five-character password using scrypt is stronger than a ten-character password using openssl. As for "like tarsnap", one of the nicest bits about tarsnap, on top of it actually using modern crypto primitives, is the key management system. You can allocate each machine its own unique passphraseless append-only keys which can only create new archives, while keeping keys to delete or restore separate, either passphrased or even air- gapped. How easily can you replicate that with S3? And of course, deduplication, mumble mumble, even if S3's 10x cheaper. ---------------------------------------------------------------------- ewood87 · 2014-08-21 16:44 Ah, good point. Didn't realize this was for something in production. I assumed it was just a personal VPS. ---------------------------------------------------------------------- godlesspeon · 2014-08-21 19:18 Fair points there all around. TBH OpenSSL is a giant crypto graveyard so you're right. I'm going to rewrite my scripts today. The approach I've been using is 7 years old so it's time for a change. Thanks for your insights! ---------------------------------------------------------------------- hemmar · 2014-08-22 03:28 https://box.com also works. If you don't want to spend time on the API you can script around a DAV client such as cadaver. http://www.webdav.org/cadaver/ ---------------------------------------------------------------------- neoice · 2014-08-22 04:05 I always use `openssl aes-256-cbc -e /path/to/file`: is this a different code path? (subcommand aes-256-cbc vs subcommand enc) ---------------------------------------------------------------------- Freeky · 2014-08-22 04:31 Nope, just an alias. See [apps/progs.h](https://github.com/openssl/op enssl/blob/master/apps/progs.h#L200) - just calls enc_main, [same as the enc subcommand](https://github.com/openssl/openssl/blob/master/app s/progs.h#L76). Can also verify by seeing the usage output from both subcommands is identical, and that it only occurs in [the enc subcommand's source file](https://github.com/openssl/openssl/blob/master/apps/enc.c). ---------------------------------------------------------------------- PillowShip · 2014-08-22 21:47 Please note that Tarsnap uses compression on your files, and only sends incremental changes over the wire (... saving you bandwidth on your VPS, and bandwidth charges from Tarsnap.) As long as you're not backing up your MP3 or movie collection, Tarsnap is actually very affordable. ---------------------------------------------------------------------- PillowShip · 2014-08-22 21:52 Another excellent alternative is [SpiderOak](http://www.spideroak.com). 2GB free for life, $100/yr. for 100GB (50% discount for students.) * All of your data is compressed, encrypted, de-duplicated across devices. * They have zero-knowledge of your data. * Unlimited Devices (multiple servers/laptops/etc.) * Java-based: Mac/Win/*nix clients available (**to include CLI**) * US company. :] ---------------------------------------------------------------------- pentag0 · 2014-08-23 06:10 What about jail archives? They range from 250-600 megs.. ---------------------------------------------------------------------- pentag0 · 2014-08-24 10:29 Being US company isn't really representative feature any more you know :) ---------------------------------------------------------------------- PillowShip · 2014-08-24 23:44 I try to avoid political debates, but I bet we could probably agree that it's not *the worse* place to store all of your data. ;) ---------------------------------------------------------------------- PillowShip · 2014-08-24 23:56 The point i'm trying to make here is that most modern multimedia codecs utilize large amounts of compression. (When your 100MB .wav file turns into a 4MB .mp3, the resulting .mp3 is composed of lots of seemingly random data. 'Random' data compresses poorly. This same concept applies to JPEG images, most encoded movies, etc.) If your jails hold large amounts multimedia content, they will compress poorly, and therefore, take up more space to backup, and more bandwidth to transmit. However, if your jails contain large amounts of easily compressed documents (source code, old Word documents, ...) they will compress down to a more reasonable file size, and therefore cost less to store, and less bandwidth to transmit. *Tarsnap is fantastic and cheap.* I'd recommend putting $5 into an account, and watch how far that gets you, based on the data you are storing. I predict you will be surprised. ---------------------------------------------------------------------- techsnapp · 2014-08-25 03:03 They should improve their SSL: https://www.ssllabs.com/ssltest/analyze.html?d=cyphertite.com ---------------------------------------------------------------------- ryanjkirk · 2014-09-05 04:59 Cyphertite is excellent, I highly recommend a go with the service.