384 points · by drevil-v2 · 6y ago · 253 comments
- open up private browsing
- press F12 (or however you get the developer console on a mac) and go to the networking tab
- go to gmail.com say
- enter your gmail credentials
- look at the post request generated, and at the request tab, it will contain your password in plain text
So passwords don't get hashed on transit, this is why having HTTPS is so crucial, which is to prevent someone in the middle (say when you connect to an open Starbucks wifi) from sniffing out your unencrypted password. The password on the server side initially can be unencrypted before it gets hashed to be stored into the database. So in this instance, the password in the database is hashed, but there is a small period where the password is plain text in memory.
For a site called hacker news, it's really sad how little people here know about hacking.
I appreciate they where trying to protect passwords & promote security, but it definitely caught me off guard that this wasn't widely understood.
I think you meant "don't get"
Hashing in the client leads to a fair share of security issues, especially if it's not also hashed on the backend using the usual salted hashes.
There are protocols like SRP to do it securely, but it's non-trivial. And remember that such protocol is only useful if you trust the client implementation—it's kind of pointless for a third-party webpage or app.
Use randomized per-site password. Solves everything.
I've yet to see someone give a good reason to not hash on the client and the server... I would be curious to hear if you have any.
It's definitely non-standard though.
2. It provides no additional security in the authentication process.
3. It provides no additional security-at-rest for post-breach protection.
Doing something like that ends up in the dangerous bucket of duct-tape crypto. I don't mind people playing with crypto, but things are not as simple as they seem, and "more" is not necessarily better.
Sure, if you're foolish enough to not hash on the server side then you're setting yourself up for failure. But I fail to see what the problem with hashing on the client side is?
You shouldn't be sending passwords in any form over unencrypted HTTP, and there isnt a clear case for hashing or obscuring the password over HTTPS.
Hashing the password on the client limits the password entropy to entropy of hash you generate. Any addition entropy in the original password is thrown away.
Also naive hashing in the client just turns the hash into your password, all of the standard issues of transmitting passwords still exists (such as replay attacks as you mention).
If password is sent over HTTP in plaintext, then password can be used in a replay attack.
Of course you can also do a dozen other things with it, such as attack other sites.
And of course this flaw is trivially rectified by having the site send a nonce.
E.g., if your user-agent does it all for you, you could consider it trusted, but if all the code is provided by the "untrusted" service-provider that you won't want to see your password, it ends up just being for show.
Similar situation with ProtonMail: As long as you use the clients shipped by them (webmail, app), all of the security hinges on nothing but a promise. Their app can read the passwords and keys as much as it wants.
I also found out that protonmail doesn't seem to send the password in plain text in the post request itself. Really keen to see how they do it as well.
Allen-Ebrahimian has focused on the crackdown against peaceful pro-democracy protestors in Hong Kong and the dismantling of "one country, two systems" (1), genomic surveillance of ethnic minorities in Xinjiang (2), and Huawei (3), among other topics. Last week, a CCP mouthpiece publication labelled her an "anti-China journalist" for her work (4).
She also uses WeChat for research (5).
I believe her WeChat account was very closely monitored, more than the average Western user.
1. https://twitter.com/BethanyAllenEbr/status/12634694294358835...
2. https://twitter.com/BethanyAllenEbr/status/12682239479397457...
3. https://twitter.com/BethanyAllenEbr/status/12063586414246830...
4. https://twitter.com/BethanyAllenEbr/status/12657932056285552...
5. https://twitter.com/BethanyAllenEbr/status/10961659522643312...
Be that as it may, it doesn't explain why WeChat appears to be storing or transmitting plaintext passwords. That's incredibly alarming, if true. As are the implications of such a design.
Look at it from the state's perspective: You have nearly unlimited control over your population, but you still can't read their minds. Given how common password reuse is, why wouldn't you track everyone's passwords in case you want access to data stored on systems that aren't already integrated into your sweeping surveillance system?
In the mediocre, they are sent to a server-side app and hashed without being analyzed, and stored in their hashed/salted state.
No good service analyzes your password server side, much less for the offensive nature of your password.
edit: Okay, I suppose there can be some analysis of password strength server-side before hashing at rest. Still, it should not be analyzed for the social acceptance of its content.
That the banning came with a short delay makes me guess that they scan all input to their app, indescriminately. They just send all keystrokes to their censorship server and check them there, and apply penalties if neccessary.
The reason they would do this is because WeChat is actually many apps in one. Third parties can embed mini apps as HTML pages in their profiles. For example, when in China I used a WeChat applet to control a coffee vending machine. In order to monitor content in every app, it makes sense to just blanket scan the inputs. Someone brave could test this by typing offensive things into some text field but not submitting them.
edit: I'll take back most of my comment here because it was admittedly hard to read and slightly out of context.
I am not suggesting that this is what WeChat does, but I think it is possible to have a blacklist without plaintext transmission.
Assuming they want to check against all casing combinations, the list of hashes would be 3 orders of magnitude bigger for a list of 7 letter words. If they want to check for substrings or spelling variations, list would combinatorially explode.
At the time, (most) every store in the world had a 56k frame relay network connection back to the Bentonville, Arkansas home office. The main purpose of this connection was to do various credit/debit/EBT,check/etc authorizations.
Stores in China had something additional: a fractional 56k frame link, the far end terminated by some other entity.
Normally, in store point of sale systems sent authorizations to the then named VISA system in Bentonville. (It was called VISA but it handled most electronic transaction types. It was replaced by a far more robust and generalized system called E-Pay shortly thereafter.)
In China, the POS systems also sent the transactions across that other link.
We didn't know officially who was on the other side, but it was widely speculated that it was the Chinese government.
My knowledge of these things is nearly 20 years old now, do take my recollections with a grain of salt. Also, I have no idea how this setup has subsequently evolved.
Someone is probably watching closely what this reporter is doing.
I've seen worse user experiences.
But yeah lets just go with the passwords are in plaintext and she's a journalist beijing doesn't like as the only possible outcome. Thats the explanation I'm going to go with when Facebook security reviews blindside my new accounts and close it unilaterally.
AT&T does the same thing.
https://gizmodo.com/why-at-t-wont-let-you-swear-in-your-pass...
This only proves they aren't encrypting passwords on the fly. And have, and do, the ability to read your password.
Honestly, I don't know why anyone uses WeChat. In China it's a requirement but for any other reason give it a hard pass.
Not really, even if you have password hashing, the password is always in the clear when you're attempting an login or you're setting it. They can simply run the detection system then, without loss of security.
Not anymore. Modern logins should use something like SRP, which doesn't send a password over the wire on every login.
However, it is difficult to draw any conclusions from a tweet.
The author is a journalist covering China so she might already had performed various 'tests' on her WeChat account that raised various red flags for various reasons until her account ended up being flagged for deletion.
If they are really checking cleartext passwords against 'offensive' keywords they are impressively thorough, tbh, but it would still seem odd to delete an account just like that instead of rejecting the password so I'm thinking that there is more to her story, if it is true.
Not at all. They could simply be checking against rules before hashing the password. Pretty much any passworded system already does this in order to enforce minimum length rules.
If that's their password length checker, they've got the maddest password length check design I've ever heard of.
In the story, they gave him no warning that the password was prohibited, or why, and then permanently deleted the account with no recourse.
That's pretty different from "oh we don't allow that, pick another one", even if the latter is also annoying.
/She/ is also a well known journalist who could easily have had her account being monitored. Other people on that thread claimed that they changed their password to the same and nothing happened.
I read the top 3 tweets there. She doesn't say how, within 45s, she was informed of the account closure?
If she just couldn't login, for example then it could simply be she mistyped the password.
The narrative of how she just suddenly decided to check if writing FuckCCP89 in the password field would cause any effect seems distinctly unlikely. If she had a tip-off that it would have an effect, then fair enough; but she should note that and add credence to her story.
Not convinced.
I'm not sure we can determine the verity of it.
- password goes through filter check onSubmit and some flag is set on the account immediately, it's added to a queue, pw is hashed and stored
- "account moderation" worker picks up task from its gigantic queue of Chinese accounts that need some automated action taking on them, bans account, notifies user, does whatever else needs to be done when closing an account for a service like WeChat
Edit just to remark: a lot of people commenting on this thread are making some pretty big assumptions about both what apps do do and should do with passwords.
In my experience, you can more or less say this: most companies and applications in 2020 do hash passwords before storing them in the database.
Beyond that, all bets are off.
Just in terms of security policies this is nuts.
Inspecting the political contents of passwords is nuts and tyranny.
Inspecting the contents of passwords at all is nuts and spectacularly bad.
Like choosing business associates based on their politics, just at a larger scale.
Evaluating a passwords' strength or complexity is incredibly routine.
Because the CCP is a totalitarian state with an interest in controlling expression, even in passwords?
Just because WeChat does numerous, dislikable things, doesn't mean they monitor passwords. Or did this.
Surely the least likely of all possible explanations, but an easter egg blocking passwords that are variations of "I refuse to cooperate" would be a hidden artistic statement in its own way.
Would you trust the third party that flagged this as offensive:
F*ckCCP89
Edit: given that her account was permanently deleted after just 45 seconds, I actually think some party member working at WeChat is monitoring her activities in real-time. The password probably get him angry enough to push the permadelete button.
Would a native Chinese speaker even have that visceral emotional reaction to English profanity? I'm curious about how that impact translates.
People reuse passwords, so its likely that WeChat passwords allow access to other systems (like Facebook, Twitter, Alibaba, Amazon,...)
This attack angle of just collecting passwords for government has not yet occured to me before.
And then people getting surprised from where do those ginormous plaintext password leaks come from.
All kinds of popular online forum engines were being hacked for password captures since times immemorial. PHPBB still uses server side hashing for example.
Now, for people concerned, take a look who was the party who sank crypto forms at W3C.
Direct access via the companies themselves is probably much more valuable today.
In the case of China in particular we know that part of the "Great Firewall" have IP addresses associated with Chinese residential ISPs, whether those are "hijacked" or the relevant agency just asks nicely we do not know. So it may be that "Chinese central government intelligence agency" and "My neighbour's WiFi" are similar IP addresses if you live there.
But yes multi-factor authentication can reduce the impact of credential stuffing attacks.
WeChat service will receive the password in plaintext. It's able to do processing on that plaintext value.
It is likely storing a hashed version of the password in the database.
At some point all passwords are plain text, be it on the client or whatever, they could simply check it before it is encrypted and stored, even on the client end if they wanted to.
In the OP case it could be many factors added together that led to the banning.
This underscores how precious and fragile the freedom of speech is.
As has already been stated, multipled people have tried what she did (myself included; just tried with a spare SIM)and we have not had our accounts banned.
WeChat also has little reason to ban someone a private password because that can hardly be considered a communications risk (it's not like her password is being publicly posted for everyone to read). It seems much more likely that her account was closed for reasons outside of this password change.
A few months later I also uninstalled all Facebook related apps from my phone.
Close out accounts randomly and see if someone tries to rationalize it in a disgruntled manner. If you're a Western agitator you'll complain. If you're a proper patriotic member of the CCP you'll understand that it's all for the good of the Party.
Jesus. Did I just write that?
What a world we live in where that isn't unreasonable. Then again I really shouldn't be going and giving places ideas I suppose.
"g̶o̶d̶ the ccp works in mysterious ways"
That means hackers can break in to WeChat and leak all the passwords.
>Fwiw just changed my wechat password to the same one bethany used just to test this, continue to be able to use it without incident.
https://twitter.com/BethanyAllenEbr/status/12687275190517473...