Login
You're viewing the functional.cafe public feed.
  • Nov 5, 2026, 4:42 PM

    @airtower So one thing the writeup gets wrong is that libxcrypt which also implemented these "failure tokens" as they call them to avoid returning NULL is not actually just a single character away because they chose *0 instead of * and nobody sets that in their /etc/shadow.

    1/2

    💬 1🔄 1⭐ 0

Replies

  • 💬 2🔄 0⭐ 0
  • Nov 5, 2026, 4:45 PM

    @airtower The other thing I was annoyed about was "buildroot uses musl, so it's vulnerable" in the opening paragraph.

    But I do actually want to check how easy it is to end up with a vulnerable configuration in buildroot.

    (anyway, sorry for spamming you here. I fully agree with your initial message even though I think that what libxcrypt did might be an okay tradeoff in a world full of existing broken software 🤷)

    💬 0🔄 0⭐ 0
  • Nov 5, 2026, 8:53 PM

    @airtower Okay, there's actually a bit more going on here.

    The libxcrypt design still only accidentally avoids triggering the same openssh "bug". [1]
    The musl also has a similar "if passed *, then return x as invalid on errors". (not in the too long sha512 case, but than cannot be reached by * as setting input anyway. So this is confusing to read, but afaict as correct as libxcrypt.

    The one saving grace of the libxcrypt implementation is that ~nobody has a literal `*0` set as their hash.

    1/2

    💬 1🔄 0⭐ 0
  • Nov 5, 2026, 9:01 PM

    @airtower

    [1] The openssh implementation checked valid hashes as >=2 characters long. (So in that case *0 is passed into crypt and the failsafe triggers making this fundamentally not triggerable. Just very *janky*)

    news.ycombinator.com/item?id=5 has an actually readable summary.
    and news.ycombinator.com/item?id=5 makes an argument why returning anything but NULL was considered a good idea at that time. (which was also the debian maintainers argument and why libxcrypt has this now as well)

    2/2

    💬 1🔄 0⭐ 0
  • Nov 5, 2026, 9:04 PM

    @airtower (I just wanted to correct my earlier posts here that the libxcrypt thing avoided this bug in a fundamental way. Not really trying to explain the problem to you, hope it didn't come across as such.)

    💬 0🔄 0⭐ 0