Epic fail

Posted on
Page
of 1,114
First Prev
/ 1,114
Last Next
  • Fucking fascist!

  • What kind of idiot uses varchar instead of nvarchar (i.e UTF16) for place names?

  • it's not a massive ask to change these characters to something less problematic on submission

    What, automatically, and thus store a different password from what the user supplied?

    I was thinking for a moment that you were saying the user should just retype without those 'problematic' characters...

  • If you are storing passwords at all then the fail is on you and is definitely of the epic variety.

    If you don't know why, please admit it and go and read about salted hashes.

  • This is turning into techy one-upmanship... You are right of course, but 'store' does not necessarily mean 'in plain text'.

  • Agreed to the one upmanship, let's just say that we are having a nice chat? For the benefit of other people reading this, rather than for ourselves.

    Anyway, for those who may not realise it:

    Don't reject any characters in passwords.
    Don't put a (needless) upper limit on the length of passwords.
    Do hash your passwords before storing.
    Do salt your hashes.
    Do store the salted hashes in the DB.
    Do ensure that your DB can store any value created by your hash function.
    Do compare hashes when authenticating.

    Whatever else I have forgotten.

  • The friendliest forum on the internet

  • Ketchup.

  • The friendliest forum on the internet ™

    You can shitfuck off with that kind of comment, you worsecunt.

    xx

  • The fail could be at any of the many layers of the stack, from stupid restriction by front-end designer on down. I worked on an early PaaS system where the terribly clever logging framework failed on non-Latin characters, unlike every other part of the system. Since they'd been extra clever, failure of the logging component broke the system (real talent, there).

    that said, it's not a massive ask to change these characters to something less problematic on submission.

    In the case, as here, of a city name in an app explicitly designed for non-UK citizens, you'd expect that to be being stored plain-text in a database. If the database schema didn't allow for UTF here, the designers are morons. This is a data driven app and the bounds of that data should be communicated all the way up the stack. There shouldn't be anything problematic about non-Latin characters going straight all the way back down the stack, either.

    Edit: Yes, this one shouldn't be stored, doh. But since they will have to be processing lots of non-latin character set data for the applicants anyway, any Latin-only restrictions are pants.

  • I work in banking and it's utterly bogged down with legacy systems and all I know is this shit is rife. We have people in Canada that can't open accounts because of accents grave etc.

  • It's a feature not a bug. Anyone too foreign can't stay and get rejected.

    #tinfoilhat

  • a city name in an app explicitly designed for non-UK citizens, you'd expect that to be being stored plain-text in a database.

    I don't get this bit - isn't the city name a password here, so should not be stored in plain text?

    I'm a BA though, so I'd just handwave it all as 'authenticate the user' in a vague business process diagram and the rest all comes under 'tech's problem'.

  • Oh, aye. Hash it and be done, though. "Invaid characters" be fucked.

  • Is it a password tho?

  • Yeah, fin services are not really in the business of turning people away... that's kinda the problem.

  • What's a salted hash? (serious question)
    non serious statement : it does sound yummy.
    (serious question) :is it the user that needs to have salted hash passwords? Or is it the dev side?

  • fucking Artisan passwords.....

  • It looks like the answer to a security question, so I'd be treating it like a password and not storing it in plain text.

    However, even if hashed it's vulnerable if the DB is stolen as the search space for possible answers to security questions is much less than for freely chosen texts of passwords.

    (Unless, of course, your answers to security questions like the city that you were born in are: "#3ak2@}-Zoe29!bb$-")

  • Whatever else I have forgotten.

    Don't even think about implementing your own bit of code to handle passwords unless you really, really, really, really need to?

  • What's a salted hash?

    I think you're meant to smoke it.

  • What's a salted hash

    What you need to know for this conversation is that with a hash function you can't derive the input from the output. If that were the only characteristic, modulo 10 would be a hash function. If the output is 3, you don't know if the input was 3, 13, 53 or 1003. Obviously that isn't useful for password systems as one in 10 guesses would get you a login. Actual hash functions have a rather larger number of possible outputs which are "scattered" so that knowing the result for "bed" doesn't help you guess the result for "bee".

    So the basis of most password systems is the storage of the output of a hash function applied to the password.

    Time was, it was enough to simply store the hash. Even if somebody stole the password database, they couldn't just work backwards to the passwords. They'd have to a) know the hash function used (although there are only a few ones in common use) and b) run all the possible character combinations through the hash function until they found a match.

    Then Moore's Law kicked in and it became quite feasible to do this. Particularly if you had the whole password database, since you could crack all of the passwords in one pass. So a randomly-chosen short sequence of bytes - the salt - would be added to the password before it was hashed. The salt would be stored alongside the password - which might seem unhelpful but the aim isn't to make one password harder to crack but to make a password database much harder to crack in a single pass, since for each possible password sequence you now also have to try each possible salt.

    Even today, storing passwords in plain text is surprisingly common in incompetent/careless/unprincipled businesses.

  • Thank you. Good answer.

  • -Hits imaginary rep button-

    Very informative - cheers for sharing

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

Epic fail

Posted by Avatar for Build @Build

Actions