Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Powered Descent
Jul 13, 2008

We haven't had that spirit here since 1969.

Storm One posted:

Why would anyone use a block cipher with 64 bit block size?

For anything smaller than a few gigs, it's perfectly fine. But it's just as easy to use AES-256 or whatever you prefer. (I just picked Blowfish since it makes for nice compact commands.)

e: GPG is a fine choice here too.

Powered Descent fucked around with this message at 00:16 on Jun 17, 2021

Adbot
ADBOT LOVES YOU

CLAM DOWN
Feb 13, 2007




Storm One posted:

Just use symmetric GPG, it's the de facto standard.

Achmed Jones
Oct 16, 2004



tbh id probably go asymmetric so that secret doesn't need to live on the server that's doing the encryption but yeah use gpg

Storm One
Jan 12, 2011
EDIT:

Achmed Jones posted:

tbh id probably go asymmetric so that secret doesn't need to live on the server that's doing the encryption but yeah use gpg

I wouldn't because then they'd also need to backup and manage the keypair. A simple password that's written down on paper and can even be the same as the master password for the Bitwarden DB is more shoot-yourself-in-the-foot proof.

Powered Descent posted:

For anything smaller than a few gigs, it's perfectly fine. But it's just as easy to use AES-256 or whatever you prefer. (I just picked Blowfish since it makes for nice compact commands.)

Sure, but that OpenSSL one-liner doesn't use any authentication (GPG's apparently isn't ideal but it's something at least) and it's harder to memorise than
code:
EXPORTCOMMAND | gpg -c > encrypted.gpg
for encrypting, and for decrypting
code:
gpg -d encrypted.gpg > decrypted
or simply
code:
gpg encrypted.gpg
and GPG will look at the file header and prompt for a filename and password automatically.

It's cryptographically better, simpler to use, and GPG is installed in all Linux distros and easily available for Windows, etc

Why fuss with OpenSSL?

Storm One fucked around with this message at 00:28 on Jun 17, 2021

Powered Descent
Jul 13, 2008

We haven't had that spirit here since 1969.

Storm One posted:

Why fuss with OpenSSL?

It's just the tool I'm more familiar with (we used it a lot at an old job) so it's what sprang to mind for encryption of one file from CLI.

Anyway, suggestion withdrawn, I'll join you on board the GPG train now.

Ynglaur
Oct 9, 2013

The Malta Conference, anyone?
Yeah, good point on GPG over 7-Zip. I live in Windows land and that's my default go-to, so thanks Goons for teaching me something new!

If anyone has anything on that reference to 7-Zip encryption being bad I'd be interested in reading it. It's a very long-lived application that's had a lot of changes over the years, so I'm also curious how recent that criticism is.

azurite
Jul 25, 2010

Strange, isn't it?!


I'm not qualified to authoritatively conclude anything about this, but someone recently tweeted that they fuzzed 7zip and found lots of problems. I believe it was reposted somewhere in this thread.

Achmed Jones
Oct 16, 2004



Storm One posted:

I wouldn't because then they'd also need to backup and manage the keypair. A simple password that's written down on paper and can even be the same as the master password for the Bitwarden DB is more shoot-yourself-in-the-foot proof.

print out the private key and put in a safe. it's more annoying to type in but it's not particularly different from a password. we have base64 (or whatever you want) technology. pub keys are both public and recoverable from private keys so backing up a "pair" doesn't make a ton of sense

Storm One
Jan 12, 2011

Achmed Jones posted:

so backing up a "pair" doesn't make a ton of sense

True, I mispoke. I personally prefer to only have to worry about remembering and keeping a backup of my master password but if anyone needs/prefers to use asymmetric GPG and wants to backup their private key, the way to go is using paperkey.

quote:

Due to metadata and redundancy, OpenPGP secret keys are significantly larger than just the "secret bits". In fact, the secret key contains a complete copy of the public key. Since the public key generally doesn't need to be escrowed (most people have many copies of it on various keyservers, web pages, or similar), only archiving the secret parts can be a real advantage.

Paperkey extracts just those secret bytes and prints them. To reconstruct, you re-enter those bytes (whether by hand, OCR, QR code, or the like) and paperkey can use them to transform your existing public key into a secret key.

Different key algorithms will benefit to a different degree from this size reduction. In general, DSA or Elgamal keys benefit the most, shrinking to around 10% of the original key size, and RSA keys benefit the least, only shrinking to about 50% of the original key size. ECC keys are in between, shrinking to around 20-25% of the original, but of course, ECC keys are quite small to begin with, and 25% of a small number can compare well to 10% of a larger number.

As with any backup or archiving system, it is prudent to verify you can restore the key from your paper copy before filing the paper away.

Note that paperkey does not change the security requirements of storing a secret key. In fact, paperkey doesn't do any crypto at all, but just saves and restores the original secret key, whether it is encrypted or not. If your key has a passphrase on it (i.e. is encrypted), the paper copy is similarly encrypted. If your key has no passphrase, neither does the paper copy. Whatever the passphrase (or lack thereof) was on the original secret key will be the same on the reconstructed key.

Note that using paperkey, a backup of the public key is also needed in order to reconstruct the secret key.

Rufus Ping
Dec 27, 2006





I'm a Friend of Rodney Nano

RFC2324 posted:

This reminds me of something. Bitwarden can do a database dump in an few formats. I'm doing a nightly dump in their encrypted_json format but thats proprietary and can only be loaded back into bitwarden. I wanted to modify the dump to output one of the non-proprietary formats and pipe it into something to encrypt it... Any recommendations?

This is linux cli btw

Ideal use case for tarsnap, OP

RFC2324
Jun 7, 2012

http 418

thanks for all the advice. I'll get gpg written into my backup script

azurite posted:

I'm not qualified to authoritatively conclude anything about this, but someone recently tweeted that they fuzzed 7zip and found lots of problems. I believe it was reposted somewhere in this thread.

this is what I was talking about. I don't know that more was ever revealed that 3-4 tweets worth of 'welp, time to not trust 7zip for encryption'

spankmeister
Jun 15, 2008






Powered Descent posted:

(I just picked Blowfish since it makes for nice compact commands.)

This is an absolutely terrible reason to choose an algorithm. From a "don't roll your own crypto" post no less.

Pablo Bluth
Sep 7, 2007

I've made a huge mistake.
Isn't GPG a dumpster fire of overcomplexity and outdated design that people want to go away but won't?

Is there a decent file encryption tool based on libsodium?

Rufus Ping
Dec 27, 2006





I'm a Friend of Rodney Nano
Not libsodium but perhaps age fits the spirit of what you want

Storm One
Jan 12, 2011

Pablo Bluth posted:

Isn't GPG a dumpster fire of overcomplexity and outdated design that people want to go away but won't?

Is there a decent file encryption tool based on libsodium?

Yes if you care about the whole of the OpenPGP spec. OP doesn't, they just want a simple symmetric encryption tool which GPG can also do, though not as elegantly as desired.

GPG is not ideal but it is cryptographically sound (not broken) and widely available.

age isn't even packaged in current Debian, though it will be in Bullseye. Still, unless something critically flawed with GPG's symmetric encryption is found, I'll take the tool bundled by default in all Linux distros for more than a decade over whatever fad du jour. Give it 10 more years and if age is still the reference I'll switch to it.

Ynglaur
Oct 9, 2013

The Malta Conference, anyone?

RFC2324 posted:

thanks for all the advice. I'll get gpg written into my backup script

this is what I was talking about. I don't know that more was ever revealed that 3-4 tweets worth of 'welp, time to not trust 7zip for encryption'

Eh, unless it was Tavis Ormandy or someone equally reputable I don't think I'd make serious software or security decisions based on a tweet. That said, of you work in a field where you need absolute trust in the software you're running, then get ready to independently audit every piece of code you run, which is fine but probably means Twitter is still not useful for that purpose.

evil_bunnY
Apr 2, 2003

https://blog.fuzzing-project.org/49-Multiple-issues-in-p7zip.html

Sheep
Jul 24, 2003
p7zip is an abandoned fork done by an independent developer and not "official" 7zip, and certainly not under active development aside from that fork some dude has on Github that may well have its own issues. If you depend on half-decade old versions of abandoned projects then you obviously have to deal with the baggage that comes with that.

Nothing in that post should really be taken as representative of the current state of 7zip.

Sheep fucked around with this message at 14:37 on Jun 17, 2021

Jabor
Jul 16, 2010

#1 Loser at SpaceChem
Yeah, imagine using the most recent version of software offered by your OS distribution. Surely Debian wouldn't be shipping ancient software with unpatched CVEs, right?

Powered Descent
Jul 13, 2008

We haven't had that spirit here since 1969.

e: Never mind, not worth arguing over.

Powered Descent fucked around with this message at 15:01 on Jun 17, 2021

BlankSystemDaemon
Mar 13, 2009



Jabor posted:

Yeah, imagine using the most recent version of software offered by your OS distribution. Surely Debian wouldn't be shipping ancient software with unpatched CVEs, right?
I'm curious, do you contribute to an open source project in some way?

Jabor
Jul 16, 2010

#1 Loser at SpaceChem

BlankSystemDaemon posted:

I'm curious, do you contribute to an open source project in some way?

What does that have to do with anything?

vanity slug
Jul 20, 2010

the only thing i hate more than dealing with outdated packages is dealing with open source project contributors

BlankSystemDaemon
Mar 13, 2009



Jabor posted:

What does that have to do with anything?
It seems to me that what you're implying is that Debian are aware of when they make mistakes by missing something, but do it anyway?
I'm not sure you'd be making that assumption, if indeed you are, if you knew how much work is involved in being involved with one of these large projects, especially considering how much of it is volunteer work.

Sickening
Jul 16, 2007

Black summer was the best summer.
I am honestly lost at what point any of you are actually trying to make.

azurite
Jul 25, 2010

Strange, isn't it?!


https://twitter.com/AdmVonSchneider/status/1369300173441089538?s=20

It was this thread, I believe. The poster does go on to eventually say the latest upstream versions of 7-zip are better.

Klyith
Aug 3, 2007

GBS Pledge Week

Sickening posted:

I am honestly lost at what point any of you are actually trying to make.

Infosec best practice: don't use any software.

BlankSystemDaemon
Mar 13, 2009



Klyith posted:

Infosec best practice: don't use any software.

Diva Cupcake
Aug 15, 2005

Klyith posted:

Infosec best practice: don't use any computer.

RFC2324
Jun 7, 2012

http 418

Klyith posted:

Infosec best practice: don't use any software.

CommieGIR
Aug 22, 2006

The blue glow is a feature, not a bug


Pillbug

Klyith posted:

Infosec best practice: don't use any digital device ever. The age of the computer is over, the time of the horse has returned.

Absurd Alhazred
Mar 27, 2010

by Athanatos

Klyith posted:

Infosec best practice: don't

DrDork
Dec 29, 2003
commanding officer of the Army of Dorkness

BlankSystemDaemon posted:

It seems to me that what you're implying is that Debian are aware of when they make mistakes by missing something, but do it anyway?
I'm not sure you'd be making that assumption, if indeed you are, if you knew how much work is involved in being involved with one of these large projects, especially considering how much of it is volunteer work.

That open source projects of any complexity Are Hard does not obviate the reality that large projects do, in fact, make mistakes and have oversights and more than occasionally end up pushing distros out the door with CVEs still in them.

The point isn't "lol u oss guys are turds" as much as "just because it's pre-packaged doesn't guarantee anything." Though it does at least make it more likely that the package isn't a total poo poo-show, and giving preference for pre-installed packages does make sense, generally. But doing your own due diligence is always the recommendation.

wolrah
May 8, 2006
what?

Klyith posted:

Infosec best practice: don't use any software.
At least software can be easy to patch and rarely goes out of its way to sabotage you, the meatware is often the most exploitable part of a system and it's often actively hostile to attempts to solve that problem.

Cup Runneth Over
Aug 8, 2009

She said life's
Too short to worry
Life's too long to wait
It's too short
Not to love everybody
Life's too long to hate


Infosec best practice: don't use any employees.

Sickening
Jul 16, 2007

Black summer was the best summer.

wolrah posted:

At least software can be easy to patch and rarely goes out of its way to sabotage you, the meatware is often the most exploitable part of a system and it's often actively hostile to attempts to solve that problem.

Why is this the first time I have heard the term meatware? I hate it.

Butter Activities
May 4, 2018

Cup Runneth Over posted:

Infosec best practice: don't use any employees.

Just don’t have any information

Unrelated doing some reading today and apparently the reason a lot of NSA tools are known to be tied to the NSA is because the NSA rolled their own crypto and while it actually worked it was unique enough that it became a unique fingerprint, which I thought was interesting.

Ynglaur
Oct 9, 2013

The Malta Conference, anyone?
The Something Awful Forums > Serious Hardware /Software >The Infosec Thread: Don't use any software. Or people.

Jabor
Jul 16, 2010

#1 Loser at SpaceChem

BlankSystemDaemon posted:

It seems to me that what you're implying is that Debian are aware of when they make mistakes by missing something, but do it anyway?
I'm not sure you'd be making that assumption, if indeed you are, if you knew how much work is involved in being involved with one of these large projects, especially considering how much of it is volunteer work.

I care about outcomes. If the outcome is poo poo then it doesn't matter that the people putting the work in had good intentions.

But mostly I was pointing at that "just trust the tools shipped with your distro and don't think about it", and "if you use ancient unpatched software with known CVEs then it's your own fault and you deserve what you get" are actually fundamentally incompatible positions given current reality, which is something that's a surprise to many people.

Adbot
ADBOT LOVES YOU

Proteus Jones
Feb 28, 2013



Sickening posted:

Why is this the first time I have heard the term meatware? I hate it.

Wetware is the term I've heard before. It's not much better.

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply