• M137@lemmy.world
    link
    fedilink
    arrow-up
    22
    ·
    11 hours ago

    It’s hilarious how all OP did with this post is show everyone how dumb they are.
    Seriously, how do you NOT understand the security risk of that?

  • RogueBanana@piefed.zip
    link
    fedilink
    English
    arrow-up
    6
    ·
    17 hours ago

    Cisco VDI took their security to another level. Wrong password? system down? account locked? Always “Please try again later or contact support”.

  • rizzothesmall@sh.itjust.works
    link
    fedilink
    arrow-up
    124
    arrow-down
    1
    ·
    1 day ago

    Being able to determine if a username is valid without a valid password is a security flaw

    Even something as simple as taking longer to validate the password when the username is a valid one can also lead to user enumeration

      • marius@feddit.org
        link
        fedilink
        arrow-up
        2
        ·
        10 hours ago

        There are also a lot of websites where you first just enter a username and only when that is valid they ask for a password

      • howrar@lemmy.ca
        link
        fedilink
        arrow-up
        3
        arrow-down
        3
        ·
        18 hours ago

        That’s easy to do. You just check that the username exists. If someone enters a wrong username/password pair, you can still check that the username exists, but how do you know that the user intended to log in with that username? You would also have to check every other username to see if the password matches, and that can’t be done with a simple search because you need to compute a different hash for each user you check. Then if the username exists and the password also happens to match someone else’s password, then what do you report? Should you even report it? Because doing so reveals that someone had that specific password, and if the list of usernames is publicly available (which they often are, or could become public through a leak of some sort), then you can brute force over a small set of usernames to match them up.

    • theo@lemmy.world
      link
      fedilink
      arrow-up
      14
      arrow-down
      1
      ·
      1 day ago

      I was having a chat about this with a UX guy. His argument for using a similar flow was that the username/email will have to be validated at the point of registration anyway so you might as well make it easier for the user when the email is wrong. I couldn’t really refute this logic.

      If you throttle both login and registration, then surely the risk is minimised while keeping the user happy?

      • LeapSecond@lemmy.zip
        link
        fedilink
        arrow-up
        19
        arrow-down
        1
        ·
        1 day ago

        You see the registration problem in so many places. If the username is an email, the proper way to validate it without revealing if an account exists is to accept any email address and if it already exists say that in the registration email you would send anyway. With the appropriate throttling if needed.

        • theo@lemmy.world
          link
          fedilink
          arrow-up
          1
          ·
          11 hours ago

          Compared to login or password reset, you rarely see the email validate before register flow, especially for mobile apps etc. That makes it pretty hard to make the case that this needs to be actioned from a security perspective when even the big companies are not following it either.

      • qqq@lemmy.world
        link
        fedilink
        arrow-up
        2
        ·
        21 hours ago

        I pretty much always recommend throttling. It’s a very low severity issue generally, but of course it depends on the product. There might be some products where it is a very big deal

      • bleistift2@sopuli.xyz
        link
        fedilink
        English
        arrow-up
        21
        ·
        1 day ago

        I don’t know who is password, or why is password, or when is password, but I do know where is password, and it’s out there!

      • palordrolap@fedia.io
        link
        fedilink
        arrow-up
        6
        arrow-down
        4
        ·
        1 day ago

        *whose

        “who’s” is “who is”[1] or “who has”[2], and it can be wrestled into a possessive if you make “who” all or part of a name[3], but it’s the wrong sort of possessive for this context. If you really want the possessive form, it ought to be phrased “which person’s”, which is mostly what “whose” means.

        (An actual linguist would speak more about the genitive and how it works in English, but I’m not as capable.)

        [1]: e.g. “Who’s there?” [2]: e.g. “Who’s let the cat out again?” [3]: e.g. “This is you-know-who’s box of tricks.”

        • gwl [he/him]@lemmy.blahaj.zone
          link
          fedilink
          English
          arrow-up
          2
          arrow-down
          2
          ·
          11 hours ago

          Noun

          prescriptivism

          (linguistics) The practice of prescribing idealistic norms, as opposed to describing realistic forms, of linguistic usage.

          E.g.

          • Most linguists in this age believe that prescriptivism is outmoded and should no longer be used
          • Most linguists in this age believe that descriptivism is a more accurate model of language than prescriptivism
          • Most linguists in this age believe that “correcting” language though is actively harmful, as it stifles the evolution of a living growing thing, which prescriptivism fails to accurately model
          • Most linguists in this age agree the more important factor is CONTEXT, that you should use the correct language style for the context, whereas prescriptivism falls flat as it ignores context. Contextual Language is the idea that you use a different style of language talking to your boss then you do too your friend, then you do to your best friend, than you do to a stranger
          • palordrolap@fedia.io
            link
            fedilink
            arrow-up
            2
            ·
            10 hours ago

            I envy these linguists’ ability to either not be irked by grammar errors at all or to be able to deal with their irritation when errors arise.

            • gwl [he/him]@lemmy.blahaj.zone
              link
              fedilink
              English
              arrow-up
              1
              ·
              2 hours ago

              They actually are the reverse of irked, cause like an archaeologist finding a new artefact, they find the cool thing of evidence of the shift of language.

              Not errors, evidence of change

            • lad@programming.dev
              link
              fedilink
              English
              arrow-up
              1
              ·
              8 hours ago

              I also envy their ability to understand what was meant, because sometimes there are enough errors to make meaning completely impossible to discern

              • gwl [he/him]@lemmy.blahaj.zone
                link
                fedilink
                English
                arrow-up
                2
                ·
                2 hours ago

                There’s this thing in linguistics, casual language requires backchanneling - to respond back with either short utterances that show you understand, or to show confusion and then ask for clarity

                The reason formal language is formalised, as in the shit used in essays, is that there is no easy way to say “what did you mean?” - the feedback loop is far too slow for that process and by the point the author(s) get to respond they likely forget what they meant as well

                • lad@programming.dev
                  link
                  fedilink
                  English
                  arrow-up
                  1
                  ·
                  57 minutes ago

                  This makes so much sense, my most painful experience in understanding department is from forums where feedback is at best hours long, and infinitely long at worst if the person never ever replies

        • kryptonianCodeMonkey@lemmy.world
          link
          fedilink
          arrow-up
          4
          arrow-down
          4
          ·
          1 day ago

          Well, that was an entirely unnecessary and lengthy correction to a mistake that was A) a typo I didn’t notice from using swipe on my phone keyboard, not a misunderstanding on grammar, and B) not an error that rendered my comment confusing or indecipherable requiring your clarification. But thank you for your (air quotes) help. I really hope that you’re a bot, not a person this annoying or one who writes that way.

          • palordrolap@fedia.io
            link
            fedilink
            arrow-up
            5
            ·
            1 day ago

            I’m about 50/50 on grammar errors. They bother me either way, but sometimes I feel the need to correct them and try to explain why.

            Today I seem to have worded it in a way that’s rubbed people the wrong way. It has gone better. You win some, you lose some.

            And yes I know I sound like an LLM. I used to not be able to communicate my ideas at all (flashback to not being able to string a 500 word essay together at school) but then I got a job working technical support and I had to figure out a way of getting my ideas and explanations across. And this is now how I communicate, for better or worse.

            Unfortunately, LLMs learned how to communicate in a not dissimilar way. And so we sound alike.

  • waigl@lemmy.world
    link
    fedilink
    arrow-up
    61
    ·
    1 day ago

    Any further “helpful” information in that error message would be a security issue.

    • smeg@feddit.uk
      link
      fedilink
      English
      arrow-up
      19
      arrow-down
      3
      ·
      1 day ago

      I am annoyed by (but respect) APIs that take it a level further and don’t even give you a 403 to say you’re unauthorised, they just give you a 404 because anything else would acknowledge that the resource you requested actually existed

      • Pika@sh.itjust.works
        link
        fedilink
        English
        arrow-up
        11
        ·
        edit-2
        1 day ago

        I don’t respect them because most instances a 403 is more than adequate for your security. The only time I agree with having a 404 over a 403 would be file-specific pathing, but realistically the entire file directory should be a 403 instead of a 404, And then if the user is authorized to access the resource(but it isn’t there), then it gives a 404.

        • qqq@lemmy.world
          link
          fedilink
          arrow-up
          1
          ·
          21 hours ago

          Yea, it doesn’t matter too much in most instances, but there are times when it might, especially if the URL itself has some meaning embedded in it. For example if part of the path is a SHA sum of some content, which is fairly common, it might be bad to allow someone to determine if that resource exists

      • wheezy@lemmy.ml
        link
        fedilink
        English
        arrow-up
        11
        ·
        1 day ago

        Wouldn’t unauthorized only be meant for AFTER a login is successful?

        Like, the user should have to have an active session first. Maybe you’re just talking about that case though.

        • smeg@feddit.uk
          link
          fedilink
          English
          arrow-up
          4
          ·
          1 day ago

          Maybe I meant unauthenticated. What is this, mandatory cybersecurity education!?

          • wheezy@lemmy.ml
            link
            fedilink
            English
            arrow-up
            2
            ·
            edit-2
            19 hours ago

            I’m not sure. I was actually asking. And I’m not even sure enough to tell if this is a joke reply you’re making or not. Lol.

            I just assume the process is to start a general session. Rather than accessing the request to the resource directly.

            So, I guess it would be abstracted a bit though. The user COULD be successful at starting the session. Get a success response to redirect to the resource they are trying to reach AFTER the session starts. Then once they are logged in their privileges are checked on that resource. Either returning an unauthorized response or the actual content.

            So, I’d guess this is (at minimum) a two step process. Though from a user perspective they just login and get the resource.

            If the login fails it’s just a single response. I’d guess for security just a 200 response but with no session token or response.

            Honestly, I’m just typing this for my brain to try to remember the small amount of work I did with Redfish and RESTful stuff awhile back.

            But, you are right. There isn’t a reason to give the user html error codes that can tell them anything more than they should know. Without a user session or without user privileges it’s just telling users more than they should. Redirecting to a 404 page with the same generic response is probably best practice. As long as it’s consistent.

    • Pika@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      6
      ·
      1 day ago

      Not gonna lie back when websites had password hints that you could do. I used to put something like that where it wouldn’t be the full password, but it would be either a part of the password or I would label it as same as computer password or something like that.

      God, I was so insecure when I was young.

  • saltesc@lemmy.world
    link
    fedilink
    arrow-up
    20
    ·
    1 day ago

    try all passowrds. Fail

    Maybe I don’t have an account…

    create new account. email already in use. Fail.

    Okay, guess I’ll reset the password through email.

    password can’t be one already used. Fail

    WHAT?!

  • RamenJunkie@midwest.social
    link
    fedilink
    English
    arrow-up
    12
    arrow-down
    1
    ·
    1 day ago

    My bigger beef is when I enter the wrong email and it rolls me over to a sign up screen.

    Fucker, I have an account, I just don’t remeber which of my 20 email addresses it is.

  • TheFogan@programming.dev
    link
    fedilink
    English
    arrow-up
    14
    arrow-down
    2
    ·
    1 day ago

    yeah real question how would the website even know. Whole point is to match the 2 things together. Is hunter2 my password, well that depends who are you, we’ve got plenty of users that have that hunter2 password

    • Malgas@beehaw.org
      link
      fedilink
      English
      arrow-up
      0
      ·
      12 hours ago

      we’ve got plenty of users that have that hunter2 password

      Speaking of things the website shouldn’t even know…

    • GamingChairModel@lemmy.world
      link
      fedilink
      arrow-up
      11
      ·
      1 day ago

      The website could know whether the username actually exists on the system. But revealing that information is a security weakness because someone could at least learn who has an account at that site (especially if usernames are email addresses, as they often are).

      • TheFogan@programming.dev
        link
        fedilink
        English
        arrow-up
        5
        arrow-down
        1
        ·
        1 day ago

        Right but not only is it a security weakness, but it’s also not helpful to the user. Point is the username probably exists in the system.

        Say I went to a website to register TheFogan, but TheFogan already exists, so I created TheFogan2.

        3 years later I go back to the website, try and log in with username: “TheFogan” password: “Hunter2”, and it tells me “your username is right but your password is wrong”. But in reality I have the right password for my account, but the site would just think I have the wrong password for the guy who beat me to my account.

        So yeah agreed the primary reason for it is security, IE a fully user focused, while having bad security practices would be, a "if the username exists in the system, report “Username and password don’t match”, if the username doesn’t exist report “There is no user by this name in the system”. My point is the site only can know if they have a user by that username, not whether that is MY username.

    • TheYojimbo@lemmy.world
      link
      fedilink
      arrow-up
      6
      ·
      1 day ago

      Not exactly. It should check for the username and password separately. First check if the user exists, then check if the salted passwords match.

      • Pika@sh.itjust.works
        link
        fedilink
        English
        arrow-up
        3
        ·
        edit-2
        1 day ago

        Generally speaking, unless you’re using OAuth for an authentication, you would check your username and your password at the same time. It’s just you wouldn’t respond if either existed or not. You would just say invalid username and password combination.

        What gets really complicated is the hybrid SSO integrations where they use a username and then if the account has SSO enabled it then redirects you to the sign-in page, Otherwise, it brings you to a password field.

        Realistically what these sites should do to prevent that vulnerability would be to make it so you have to click a dedicated sign in with single sign on button. But not everyone does that type of flow.

        Granted, this also doesn’t include sites that convert your user account into a user ID. And then for your password’s table, only give a user ID. Those would require two queries or a join, regardless, because it’s two separate data places. One to get the user Id and one to get the passwords

  • zxqwas@lemmy.world
    link
    fedilink
    arrow-up
    10
    ·
    1 day ago

    If they told you the user name is wrong you may as well publish a list of usernames of your site.

  • chattre@lemmy.blahaj.zone
    link
    fedilink
    English
    arrow-up
    6
    ·
    1 day ago

    “Something went wrong.”

    motherfucker I will OPEN UP THE NETWORK INSPECT TAB AND FIGURE OUT WHAT WENT WRONG.

        • 123@programming.dev
          link
          fedilink
          arrow-up
          4
          ·
          1 day ago

          Had manager that wanted us to return error codes on a field of an API response along with an HTTP 200 because “errors bad”. It needed a few of us to make him understand how that worked against common design patterns and you still had to handle error codes since you didn’t know if the error would be coming from the app, web server, api gateway, local network (no internet), etc.