News for hackers. Stuff that matters.
Re:Facebook probably has your phone number, even if you neve... by addingadimensio on Tuesday November 01, 2022 @06:15PM (#33428380)
Hash and salt
Re:Facebook probably has your phone number, even if you neve... by kadoban on Tuesday November 01, 2022 @06:41PM (#33428695)
If you salt, then either you can't lookup a number, or you've only changed the problem to: iterate over all the possible phone numbers, _add the salt_ and hash them. No big difference.
Re:Facebook probably has your phone number, even if you neve... by galeaspablo on Tuesday November 01, 2022 @06:24PM (#33428481)
How could I match an incoming unhashed value to an existing salted hash?
Re:Facebook probably has your phone number, even if you neve... by m4jor on Tuesday November 01, 2022 @06:40PM (#33428684)
hashcat
Re:Facebook probably has your phone number, even if you neve... by ohbtvz on Tuesday November 01, 2022 @06:24PM (#33428482)
There are only about 3 billion valid US phone numbers. How many hashes can your GPU compute per second?
Re:Facebook probably has your phone number, even if you neve... by m4jor on Tuesday November 01, 2022 @06:39PM (#33428678)
Most people crack with multiple GPUs. For example, I have a 5 GPU (3080s) rig that I used for mining ETH but now can use to crack with hashcat. tl;dr crack fast af boiii.
Re:Facebook probably has your phone number, even if you neve... by parker_mountain on Tuesday November 01, 2022 @07:31PM (#33429286)
Back of the hand math, and some benchmarking, suggests that a consumer laptop GPU from about 2015 could bang it out in a month. And, that's being (extremely) pessimistic.

(Assuming a GPU takes .001s to do a sha3 hash, which is more than double the actual benchmarks).

I would estimate that a single, high end GPU from the last or current generation could probably chew through it in under a week.

Re:Facebook probably has your phone number, even if you neve... by DenisM on Tuesday November 01, 2022 @09:59PM (#33430588)
One can easily devise a hash function that a GPU can only compute once per second. Or per year, even, although that would be impractical.
Re:Facebook probably has your phone number, even if you neve... by nemothekid on Tuesday November 01, 2022 @07:13PM (#33429078)
The salt doesn't buy you anything, given that Facebook also knows the salt.
Re:Facebook probably has your phone number, even if you neve... by parker_mountain on Tuesday November 01, 2022 @07:27PM (#33429242)
While a secret salt is effective in the short term, it's an un-rotatable value. Which means, if the salt gets leaked, you are screwed (or rebuilding the entire table by brute forcing it, or adding another layer of salting - not great!).

For a company operating at Facebook's scale, with their kind of scrutiny around handling PII, this is unfortunately functionally useless.

For some data types where hashing isn't super effective, and where associative identifying information is attached (such as a user id), a more effective mechanism might be to encrypt the data with a strong random value appended, and decrypt to do the lookup. This would require a correctly provisioned HSM to do properly - the private key secrets should NEVER be exported.

While hashing seems like a good idea, it's actually particularly and deceptively tricky for these kinds of use cases.

Re:Facebook probably has your phone number, even if you neve... by lost_tourist on Tuesday November 01, 2022 @09:37PM (#33430435)
I would say it's better than doing nothing though.
Re:Facebook probably has your phone number, even if you neve... by parker_mountain on Thursday November 03, 2022 @08:25PM (#33460009)
It's complicated. Your local security engineer might be wringing their hands about this. Definitely an avoid at any cost kinda situation.