HNHacker News
TopNewBestAskShowJobs

odammit

1,372 karma · joined October 13, 2016

Cjchjxjakzkx
submissionscomments
odammit··on How much money do people need to be happy?
I assumed they meant largest economy?
odammit··on Announcing Google Cloud Spanner as a Vault Storage Back End
I think it’s for the convenience of people that are already using spanner and don’t want an additional data store.
odammit··on Finding Pwned Passwords with 1Password
Kinda agree about it being annoying.

I think MFA is important and have it enabled for every service that offers it, but we have MFA set up for our CLI access to AWS and I used to let out a volume of curses frequently when my token expired.

I eventually ended up adding a bash alias “damn”[0] that pipes my current MFA token into the AWS CLI so whenever it expires I can just type “damn” and be logged back in.

I like the magic link approach Slack and Medium use - although I have frequently cursed the inconvenience of having to log into gmail.

[0] why damn? Fuck was taken: https://github.com/nvbn/thefuck

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
Wow you’re aggressive.

Using something like Hashi Vault, Gluu, or Shiro does not overly complicate things. They’re stable, trusted solutions.

It can also greatly simplify things. In the common scenario of having a web app for customers and a web app for admins, instead of them each having their own authentication baked in, you can choose an open source solution and deploy it twice, once for each service.

I know how salt works. Don't belittle me.

If someone gets into your web servers they’ve pretty much got carte blanche at your database the web server has access to. They also now have your code, which in a lot of cases is probably plainly readable. So they can see your salt, see how you salt and see the hashing algorithm you've chosen.

I’m saying don’t store the salt in your apps config right along with the credentials to access all of your login identifiers and hashed passwords.

You gave them a piece of the puzzle. If someone wants to grind through and crack all the salted/hashed passwords, I'd prefer them not to have the salt to help in that endeavor.

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
Absolutely, Im not stating otherwise. Im saying you shouldnt have your authentication inside your business logic. It should be a separate service. Limited access, and transparent to the application that is calling on it.

If you want that to be a REST service, great.

If you want it to be another table/schema/database/server, great.

If you want it to be something else, great.

Just stop putting it right inside the application that is taking user input.

Don't roll your own hashing, use something solid, like Argon2, salt your stuff. Store your salt someplace secure, not in your frigging rails config.yml or inside env on your webservers or anything else that is publicly addressable.

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
They aren’t “hacking on production.” They’re occassionlly under pressure to release features. If they don’t get someone that catches a SQL injection or something else silly in a PR it’s nice to know we cant possibly bleed our password hashes.

Do you jam all your tables into one public/default schema? Or do you break them up by domain across schemas?

A very simple implementation of this in Postgres is an auth schema. Only one role can read from the table with the credentials, no app has access to that role. You write a function to verify a credential and use a security definer to give a role that can use that function access to read a single result.

In this case you’ve mitigated two “attacks”:

- a sql injection selecting all from users

- some random engineer taking a schema dump for whatever purpose, accidentally grabbing auth details and then having that get leaked somehow down the line.

I literally takes a few lines of SQL to set that up. It’s not an extra server to manage. Just a different schema with higher security constraints.

From your app with the credentials to call that compare function instead of doing a SELECT FROM you can call that function with the credentials and just accept Postgres telling you yes or no the credentials matched.

PG has a suite of hashing functions. Take your pick. That function can do your salting or you could add it as a parameter to the call.

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
The point is not putting them in a system that can leak them right alongside the login identifier.

If someone wants to go exercise 9384828388 GPUs on your list. Fantastic, at least the other piece of their auth username/etc isn’t sitting right next to it.

Putting them in a separate system can be a simple REST server that sits in front of another database, LDAP or even something like Vault.

Don’t set them right alongside your ecommerce app you’ve got 30 juniors hacking on trying to get something out ASAP.

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
^ above is pretty damn simple.

I also never said “write your own hashing algorithm” I said abstract it so it’s not sitting around in your ecommerce app code.

That is a simple security system. It’s just not baked into your flagship ecommerce, blog or whatever else your storing the credentials to protect.

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
You don’t have to “roll your own security.”

You can easily put any open source security system behind a secondary system. Hell - it would already be a secondary system.

Not putting your passwords right next to the identifiers is a simple way to lower the impact of an email or password leak.

Also, that quote is bullshit.

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
A day of engineering effort to make exposing passwords much more difficult. Yes. If you’re a company that stores someone’s password. You know they probably use it elsewhere so it’s your responsibility to help keep it safe.

Also I left the link off above ^

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
You need both.

https://www.trustedsec.com/2016/06/introduction-gpu-password...

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
Split brain your password storage.

Another table, another database or another storage system in general.

If an attacker SQL injections your database don’t go spilling every hashed or unhashed password you’ve got.

I tend to store passwords in a separate keyvalue store from where my authentication identifier is (email, “username”).

If someone gets into my network they need to get into my servers with the email addresses and then get into a secondary system where the passwords are stored.

I like my password systems to be a k/v store because there is no need to “query” it. I usually store the password under a key that isnt the identifier. Instead using something like a database surrogate key.

Have a secondary system (microservice, private subnet) that simply returns a boolean representing if the provided non-email (key) and password (value) match.

Have that secondary system take the plain text password so it can do the hashing without letting the dependent service know what algorithm, salt or stretches you’re doing. This will also allow you to easily roll over to new hashing algorithms over time without affecting the service that is doing th authenticating.

Edit: I’m not trying to be a know it all or a crabby old tinfoil hat a-hole. But it’s passwords, man. When you leak them you ruin people’s days/year/life. Building that system above takes a middle of the road engineer a day or two. Put the effort in. Every password leak makes all of our jobs harder. It’s your companies responsibility to keep that safe. If you know that already, be the annoying guy that brings it up in every stand up. Make that debt known.

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
Sure and 10k will do fine otherwise “! I thh Cher;457?:25?//(5 we” is going to suck for you user login story.

Maybe salt your passwords, use some stretches, and a decent algorithm instead of MD5, SHA1, etc.

Also stay up on algorithms and roll your users over to new ones over time.

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
WAF, IP blacklists, naive bot detection[0] and why would a decent thresholding system allow for a single IP to fail multiple accounts in a short time period.

If you hit two valid accounts [1] with bad passwords in a few ACCEPTABLE_UNIT_OF_TIME, it’s captcha time.

Thresholding isn’t just action per IP it’s being smart about how people are going to attack your system. It requires thought and upkeep.

[0] Previous thoughts on bot detection: https://news.ycombinator.com/item?id=16182405

[1] Also, if your login identifier and your public “display names” (usernames) are the same thing, that is a disservice to your users’ security.

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
Although it does happen that’s amature and unacceptable.

Either you have some EXTREME legacy or lazy engineers. Doing it right doesn’t take long.

odammit··on "Pwned Passwords" V2 With Half a Billion Passwords
If you spend the time building a system to search those half billion passwords when you’re users are signing up, you should focus on building a login rate limiting system so it’s not possible to brute force someone’s password.
odammit··on Why is it hard to make friends over 30? (2012)
Sounds like he always eats his food cold when he shows up at dinner parties.
odammit··on Why is it hard to make friends over 30? (2012)
You should get a modern phone with a calendar and alerts.
odammit··on Why is it hard to make friends over 30? (2012)
I lived in Roatan and there is a notion of “island time” you hear flying out of every lazy white mouth who is trying to sound hyper-local, but most people I met that grew up there, that work there and make plans with friends there - they tend to be pretty respectfully on-time.

Nice stereotype though!

odammit··on Why is it hard to make friends over 30? (2012)
“Punctuality obsessed” or person that takes the effort to make time to hang out with a friend, offered them the respect of showing up on time just to have their time wasted by you not showing up on time.

If you do it all the time, you’re inconsiderate.

odammit··on JavaScript Promises Discussion: Make Them Monadic? (2013)
That maybe I’ll get a burrito.
odammit··on JavaScript Promises Discussion: Make Them Monadic? (2013)
I feel like I’m being promised a burrito.
odammit··on Performance Benchmark 2018 – MongoDB, PostgreSQL, OrientDB, Neo4j and ArangoDB
Yeah after I posted it I started thinking about what it would take and what that would actually look like... and how you’d cheat :)

It would probably require a few different categories with some sort of output assertion to validate the query performed right and a means of tracking CPU, usage ram usage, and execution time.

It would be cool to see things like disaster recovery and chaos proofing as well.

odammit··on Bringing AMP to Gmail
I don’t SMS coworkers, I usually have slack threads or channels.
odammit··on Bringing AMP to Gmail
Some start up somewhere has pneumatic tubes and some little beautiful nerd is hacking them into something cool and/or funny.

I’m a little jealous.

odammit··on Bringing AMP to Gmail
I’m curious, what you all think the future of email is?

I am finding that I use it less and less each year. How much are you using it compared to previous years?

- My friend communication is done almost strictly through messaging services

- work communication is done through Slack and Jira (yuck)

I feel like email for me has become this awkward auth-proxy.

It’s how I magic link in, “confirm” who I am, reset my password, or get spammed by marketers.

odammit··on Bringing AMP to Gmail
Notes on paper airplanes. I guess that’s the UDP way.

Actually I suppose the post office is the UDP way too.

odammit··on Bringing AMP to Gmail
Ok I fold. I’m switching back to regular old postal mail.
odammit··on Flat UI Colors – Color palettes for use in projects, designs, presentations
What’s the association with countries? Is it just where designer is from?
odammit··on SpaceX craft overshot Mars’ orbit and is headed to asteroid belt
How dare I wonder.
← PreviousPage 4 of 13Next →