News for hackers. Stuff that matters.
Re:OneLogin suffers breach–customer data said to be exposed,... by devrandomguy on Thursday June 01, 2017 @11:21AM (#14461007)
On a tangent, has anyone tried using Vault as a personal keyring, rather than using a cloud based password manager? In particular, how much would I need to trust each device that runs a Vault instance, if I was concerned mainly about malware running alongside it?

Right now, I have everything in Keepass, and no good way to synchronize that between devices. Merging key repos is a royal pain, but mainly, I don't like the idea of trusting everything to an organization that I can't hold accountable. Running my own service on a generic tiny EC2 cluster feels like an improvement, although I would still worry a little about the virtual neighbors.

Re:OneLogin suffers breach–customer data said to be exposed,... by simias on Thursday June 01, 2017 @12:48PM (#14461945)
This is probably not a good solution for the vast majority of people but it works well for me: I use pass[0] but I host my ~/.password-store on a sshfs on a server I own. Wherever I need to access my passwords I just mount the sshfs and then can proceed as normal.

Since pass supports versioning the passwords with git it would also be possible to use that, just push/pull the repository to keep it in sync. It would also give you access to the password even while offline, but I actually prefer the added security of not copying the passwords over, even encrypted.

Obviously if you want to access your passwords from, say, a Windows machine or a smartphone it won't quite do the trick.

[0]https://www.passwordstore.org/

Re:OneLogin suffers breach–customer data said to be exposed,... by rkeene2 on Thursday June 01, 2017 @01:12PM (#14462233)
Similar to "pass" is "hunter2" ( https://chiselapp.com/user/rkeene/repository/hunter2/ ) which uses a hardware security module such as a smartcard to decrypt the password and allows sharing between users in a file that can be managed by a version control system (such as Fossil or Git).
Re:OneLogin suffers breach–customer data said to be exposed,... by simias on Thursday June 01, 2017 @01:21PM (#14462350)
I actually already do that with pass and a GnuPG smartcard since pass uses gpg to handle the encryption.

You can also provide several PGP encryption keys if you want to share your passwords across several people. I believe pass lets you specify the keys on a per-directory basis, although I never actually tried to do that myself.

Re:OneLogin suffers breach–customer data said to be exposed,... by rkeene2 on Thursday June 01, 2017 @01:39PM (#14462525)
hunter2 makes multiple users a first class principle. Anyone that has access to decrypt a password can add other users to that password, in the future if that password is updated all users that have access retain the new password
Re:OneLogin suffers breach–customer data said to be exposed,... by mysterydip on Thursday June 01, 2017 @01:18PM (#14462309)
Hunter2 sounds like a reference to this: http://bash.org/?244321 Amusing if true, both dealing with passwords so it's likely.
Re:OneLogin suffers breach–customer data said to be exposed,... by rkeene2 on Thursday June 01, 2017 @01:50PM (#14462637)
It is. There are several references to that on the page and in the source.
Re:OneLogin suffers breach–customer data said to be exposed,... by mooman219 on Thursday June 01, 2017 @01:45PM (#14462593)
I understand the problem you're having with keepass. My solution for it was to store the kdbx in cloud storage then access it with a nice service called https://app.keeweb.info/. This means remembering two passwords, one for your cloud storage, and one for your kdbx file. Keeweb is open source and can be used without an internet connection if you would like to use it as your primary keepass client https://github.com/keeweb/keeweb
Re:OneLogin suffers breach–customer data said to be exposed,... by dbingham on Thursday June 01, 2017 @11:26AM (#14461061)
Please, someone build an open source solution similar to Lastpass backed by a Vault instance with browser plugins and a web front end to allow for key management. That would be amazing.

Lastpass is almost necessary for me to keep all my passwords moderately secure and still usable. But I really do not love trusting all of my info to a 3rd party.

Re:OneLogin suffers breach–customer data said to be exposed,... by UnoriginalGuy on Thursday June 01, 2017 @12:11PM (#14461558)
> But I really do not love trusting all of my info to a 3rd party.

You don't need to. You need to trust Lastpass's design.

A Lastpass database is an AES-256 encrypted blob, encrypted using a "slow" hash of your master password (PBKDF2, rounds are configurable). Lastpass don't know your password. When they authenticate you they test to see if your database is decryptable with the password you entered (after it is hashed). If you set 2F then they won't even allow attempts until 2F is satisfied (Google Authenticator is free).

Lastpass's biggest weakness is also applicable to this theoretical OpenSource alternative: Javascript. Javascript is delivered from Lastpass (for the browser extension) and after you decrypt your password database, that JS has full access to it. If a "bad guy" is able to inject evil JS between you and them, then they could trivially steal already decrypted passwords.

As I said, this weakness has nothing to do with Lastpass, it would equally apply to all password managers which integrate into the browser with an extension. In effect you've exchanged convenience for security. And you can already read the Lastpass browser extension's source code, being more open source doesn't make you immune from this issue.

So you can choose to trust Lastpass, or not, but the design is sound. Slapping the words "open source" onto something won't mitigate any of LastPass's inherent design issues, and you'd still want to follow a similar design since it is a good compromise between security and convenience. Coming up with a superior design that doesn't sacrifice convenience would be awesome, but it is a hard problem...

Re:OneLogin suffers breach–customer data said to be exposed,... by Cpoll on Thursday June 01, 2017 @02:04PM (#14462780)
> they test to see if your database is decryptable with the password you entered (after it is hashed).

At which point they have full access to your database, don't they?

> And you can already read the Lastpass browser extension's source code

Of course, it's a bit more difficult, I'm betting it's minified.

High profile open source encourages people to read the source code, if nothing else. It's possible someone would've noticed that nasty cross-domain autofill bug from a while back (https://labs.detectify.com/2016/07/27/how-i-made-lastpass-gi...). It's also possible that the community would hold the codebase to a higher quality standard, and a lot of issues would go away (only a rumor, but I've heard that parts of the LastPass codebase are a mess).

Re:OneLogin suffers breach–customer data said to be exposed,... by simias on Thursday June 01, 2017 @01:19PM (#14462319)
You're right but I would like to point out that a few things actually aren't encrypted in your vault, in particular the URL field of the form. I don't really know if they mine that for info but in theory, they could. And obviously anybody having access to your encrypted blob on your filesystem can do the same.

Also, the extension queries the server to know the number of rounds to use while deriving the master key from the password before it'll deliver the encrypted blob to the client, so in theory if they really wanted to break your password they could tell the extension that it's encrypted with a single round of the hash function (IIRC the minimum is actually two) which would make bruteforcing a whole lot easier, although still very much non-trivial.

Re:OneLogin suffers breach–customer data said to be exposed,... by UnoriginalGuy on Thursday June 01, 2017 @04:32PM (#14464322)
> it'll deliver the encrypted blob to the client, so in theory if they really wanted to break your password they could tell the extension that it's encrypted with a single round of the hash function

That's incorrect. When you change the round count your master password is re-computed, and database is re-encrypted with the new hash. The server needs to return the round count so the client can generate the correct master password hash, if you ignore that and simply calculate it for e.g. 2 rounds, the master password hash won't match and therefore the AES-256 database won't decrypt.

The way Lastpass works is straightforward... PBKDF2(password, rounds) -> AES256(hash, blob). If the rounds change then the resulting hash changes and therefore the database won't decrypt. Your second paragraph is quite confusing, in that I cannot make heads or tails of why you think you can use 2 rounds when e.g. 10,000 are specified previously. A correct round count is just as vital as a correct password in generating the correct hash.

Re:OneLogin suffers breach–customer data said to be exposed,... by simias on Thursday June 01, 2017 @05:49PM (#14465160)
I'm talking about the authentication to the lastpass server, not the decryption itself.

Lastpass won't serve you the encrypted blob if you don't authenticate with their servers. To do this it computes a different key (using a different derivation function, but using the same "master" password as the encryption key) that it uses to log into the lastpass server.

This key cannot be used to decrypt the blob because of the different derivation function, but the client asks the server how many rounds of the kdf to use for a given user by posting its email to https://lastpass.com/iterations.php . As you can see it defaults to 5000, but the client will gladly accept any value.

Therefore the server can tell the client to send a key derived from only one iteration, it which case this code is run: https://github.com/lastpass/lastpass-cli/blob/623b344e898958...

In other words if an hostile party gets access to the lastpass server they can instruct your client to send your master password protected by two rounds of sha256. If you have a strong password (as you should) it's not an issue, but clearly you can't count on thousands of rounds of the KDF as you might think.

Re:OneLogin suffers breach–customer data said to be exposed,... by devrandomguy on Thursday June 01, 2017 @02:31PM (#14463047)
Yeah, implementing a Vault client in the browser is just asking for trouble. Currently, I am copy-pasting into the browser, which has two obvious vulnerabilities: the clipboard, which is accessible to everything, and the login page, which could be running an XSS exploit.

Perhaps we could eliminate both problems, by handling authentication outside of the browser, and then injecting an auth cookie into a new browser tab?

  1. `curl site.com/login` to get the login form as HTML
  2. Extract the form submission URL and the name of the user/pass fields
  3. Pipe a key from Vault, to a URL encoded HTTPS POST request (curl again)
  4. Receive the resulting session cookie and the login-success URL from the login response
  5. Insert or replace this cookie into Firefox's jar
  6. Open a new browser tab to the login-success URL
This way, the browser never sees the password, and the clipboard never holds it. The session cookie is still just as vulnerable as ever, but is of a lower value, assuming that it alone does not grant the ability to change the user's password or PW recovery email address. The entire sequence could be scripted into an `authenticate [email protected]` command, which would depend on a connected Vault client (or some other backend scheme). I have no idea if this would work on mobile operating systems, it might not be possible to write to the FF cookie jar from another app.
Re:OneLogin suffers breach–customer data said to be exposed,... by styfle on Thursday June 01, 2017 @12:53PM (#14462006)
Thanks for this detailed description!

Is there a way to close the entry point for evil JS? For example, can you tell the extension to stop touching the DOM and injecting any code. That way the username/password can be only interacted with via the browser's chrome button?

Re:OneLogin suffers breach–customer data said to be exposed,... by UnoriginalGuy on Thursday June 01, 2017 @01:19PM (#14462323)
No practical one. The extension needs full access to the data in order to push it into a page's forms or to update them via the admin UI ("Lastpass Vault").

I believe the Chrome Web Store does check an extension's signing certificate before updates are published, so security wise that's a good thing, but realistically it remains the weakest part of Lastpass's overall design.

Re:OneLogin suffers breach–customer data said to be exposed,... by heliosAtwork on Thursday June 01, 2017 @12:51PM (#14461979)
Sure, it can happen to open source; all engineering rules still apply. The attractive part to me would be that there are more eyes on the code.

I would host my own in a google app engine or heroku and avoid a 3rd party who is more attractive to hackers due to the number of accounts they host and potential gain to criminals.

Re:OneLogin suffers breach–customer data said to be exposed,... by kasey_junk on Thursday June 01, 2017 @01:13PM (#14462250)
Thats not how many (most?) breaches occur. The situation you would run into (and worry about) is that an exploit is found in the software and then it is mechanized so that things like google app engine and heroku are scanned and user run versions exploited in mass. Open source does not prevent that, only diligent operations do. So by self hosting your are making the bet that you are doing that singularly more competently than the hosted version.
Re:OneLogin suffers breach–customer data said to be exposed,... by heliosAtwork on Thursday June 01, 2017 @01:32PM (#14462447)
No, open source does not prevent anything. There is just more transparency.

Any self hosting would need to be fully connected with automated update notifications from the "crowd" of contributors and reviewers.

I guess, it becomes a managed service at that point (since as you point out it should have reliable and secure production characteristics which does require a high level of competency). I am imagining a cloud of one for my passwords (a stateless, secure container, with disabled user access to the OS and which connects to an encrypted simple file store to keep my small sized but precious passwords).

Re:OneLogin suffers breach–customer data said to be exposed,... by UnoriginalGuy on Thursday June 01, 2017 @01:27PM (#14462421)
Just to be clear: I have nothing against Open Source at all. Open Source is great.

I was just pointing out that Open Source in and of itself isn't a security protection. If you follow the same design you'll have the same design weaknesses, Open Source or closed. The "more eyes" thing, may be true, but I'd argue popularity is more important than license in determining the number of "eyes."

I'd also caution you in assuming an exploit would be against the server side. The server holds a bunch of really hard to decrypt blobs. The client is the real crown jewel. The client browser has all of the usernames/passwords decrypted, so if you were either able to deliver an "evil" extension update, or find an exploit in the existing extension, you could extricate those credentials.

That's the real rub: You turn off extension updates and you're more secure against "evil" extension updates; but you're now more vulnerable to situations where a bug is discovered in the legitimate extension and the organisation pushes a real update to patch that. Auto-updaters in particular are both a huge benefit and a huge security hole.

Re:OneLogin suffers breach–customer data said to be exposed,... by nucleardog on Thursday June 01, 2017 @02:13PM (#14462887)
I don't know what options are still available, but the "3rd party" thing is why I ended up paying $100 or something to purchase 1Password back when it was still only available as a one-time-purchased standalone app.

Even if it's open source, I'm in no position to effectively evaluate their crypto/etc. But I can do some basic reasoning about the possible attack surfaces.

With 1Password I hold all my data, and the software that I use to view it runs completely independently of anything else. Besides a takeover of my local machine or breaking the encryption, nobody gets my data.

With something like LastPass, they hold all my data. The software that I use to view it runs in my browser. The software handling all my passwords is running in the same program that I use to execute untrusted code from the internet thousands of times a day. This has bitten them in the ass a few times.

I'd love an open source password manager solution given the turn 1Password has taken towards being a "cloud service", but for the love of god can it please be useful without tying it to my web browser.

Re:OneLogin suffers breach–customer data said to be exposed,... by StavrosK on Thursday June 01, 2017 @12:43PM (#14461899)
I use KeePass2Android and merging works very well with it. It just automatically reads from my Dropbox file and merges any changes.
Re:OneLogin suffers breach–customer data said to be exposed,... by AdmiralAsshat on Thursday June 01, 2017 @12:29PM (#14461728)
The standard advice here is to throw your KeePass vault onto Dropbox/Google Drive/OneDrive, but I agree, keeping everything sync'd is a PITA. It's a problem that needs solving, but KeePass itself is probably not keen on solving it.
Re:OneLogin suffers breach–customer data said to be exposed,... by paulryanrogers on Thursday June 01, 2017 @02:05PM (#14462800)
Keepass2 actually has reasonably good built-in merging. There are also sync plugins which could help with the cloud provider's own collision copy issues
Re:OneLogin suffers breach–customer data said to be exposed,... by NikolaeVarius on Thursday June 01, 2017 @12:41PM (#14461882)
I've been sort of sketching out a system for this in my spare time.

Something like a portable container that you can host anywhere and keeps syncing easy. What kinds of other features would you want?