Slashdot Mirror


2016 Bug Hits Text Messages, Payment Processing

An anonymous reader writes "It seems some systems are suffering from a Y2K16 bug. When 2009 ticked over to 2010, some Australian EFTPOS machines skipped to the year 2016. Coincidentally, some Windows Mobile users are also having issues with their new year SMSes coming from 2016. What function could cause this kind of error?"

30 of 340 comments (clear)

  1. Why by Anonymous Coward · · Score: 5, Funny

    Uncle Bill decided to do some coding. That's why.

  2. Some kind of... by msauve · · Score: 5, Insightful

    BCD/binary mismatch?

    0x09 = 9 decimal when interpreted as either binary or BCD.

    0x10 = 10 decimal when interpreted as BCD, as 16 when interpreted as binary.

    --
    "National Security is the chief cause of national insecurity." - Celine's First Law
    1. Re:Some kind of... by Anonymous Coward · · Score: 5, Informative

      I don't think you quite have the hang of binary (10 would be 2, not 3).

    2. Re:Some kind of... by kalidasa · · Score: 4, Funny

      Facepalm. I'm gonna get mauled for this one.

    3. Re:Some kind of... by msauve · · Score: 5, Informative

      No, I meant exactly what I said. I didn't say 0b01. 0x10 is the hexadecimal notation for "00010000" binary, which is 16 decimal.

      I used 0x10 because that's standard ANSI C (and ECMA-334 C#), and C is what seems to be spoken on /.. 0b00010000 is non-standard (but allowed by some compilers).

      --
      "National Security is the chief cause of national insecurity." - Celine's First Law
    4. Re:Some kind of... by oskard · · Score: 3, Funny

      Take it easy on him. After all, there are only 10 kinds of people in this world.

      --
      Sigs are for Terrorists.
    5. Re:Some kind of... by clone53421 · · Score: 3, Insightful

      0x10 is 16 in hexadecimal, not binary

      0x10 is still 16 in binary.

      (0x10 always means 0001 0000 in binary. The question is whether that number is interpreted in BCD, i.e. 10, or as a binary integer, i.e. 16.)

      --
      Alexander Peter Kristopeit bought his basement from his mommy for one dollar.
    6. Re:Some kind of... by clone53421 · · Score: 4, Informative

      Let me see if I can straighten it out, then.

      0x10 is a hexadecimal number, 0001 0000 binary, 16 decimal.
      0x10 is a BCD number, 0001 0000 binary, 10 decimal.

      (BCD is an encoding system, not a base system. In hex or binary it’s given in encoded form, but in decimal it’s given in decoded form.)

      --
      Alexander Peter Kristopeit bought his basement from his mommy for one dollar.
    7. Re:Some kind of... by xaxa · · Score: 3, Informative

      0x10 means 0001 0000.

      0001 0000, if that's a binary number, means decimal 16
      0001 0000, if that's binary coded decimal (BCD), i.e. decimal 0-9 represented as 0000 to 1001, means decimal 10.

      (If 0001 0000 was little endian (with 4-bit groupings) it would mean binary 1)

      1234 in binary (4D2 in hexadecimal) is 0000 0100 1110 0010
      1234 in BCD is 0001 0010 0011 0100

    8. Re:Some kind of... by Vintermann · · Score: 4, Informative

      > (a leftover relic from the mainframe era that needed to die over a decade ago)

      No no no. Binary coded decimal is necessary and useful. When you divide 1 by 10, you should get 0.1, not 0.10000000000000001 (which is what you get if you for instance open up a python interpreter and ask for 1.0 / 10.0).

      Monetary amounts, and currency conversion rates are examples of something you should never, ever use standard binary floats for.

      Fact: Many major databases use some form of BCD for representing currency values. Enough so that IBM added a dedicated decimal FPU for their power6 series - it's so common on business database servers that it actually saves a lot.

      --
      xkcd is not in the sudoers file. This incident will be reported.
    9. Re:Some kind of... by Mr+Z · · Score: 4, Interesting

      I wouldn't say it's incorrect. It's quite common to represent binary strings as hexadecimal strings regardless of the underlying format. After all, what units would you apply to an x86 opcode? what about a portion of an H.264 bit stream? Or heck, even a floating point number? 0x3F800000 is the hexadecimal representation of the IEEE 754 single precision floating point number 1.0. (And if you don't think people write floating point numbers in hex, think again.

      Now the integer 10 encoded in standard binary format would be 1010, which written in hexadecimal would be A (or 0x0A in C syntax). It also happens to be the same as if you directly went from base 10 to base 16 and ended up with 0x0A. If the decimal number were encoded as BCD, though, the resulting binary string would be written 00010000 (or 0001 0000 if you so choose--the spaces are insignificant!), and that binary string is equivalent to the hexadecimal string 0x10. Note that "hexadecimal string" does not imply base-16 number. It's just a shorter representation than the binary string. It is not equivalent to the hexadecimal number 0x10. When I said "written in hexadecimal", I meant "when written as a hexadecimal string."

      Look at it this way: If I were trying to hex-dump a file full of BCD values and the file had nothing but the value "10" (decimal) over and over in each byte, I would see 0x10 in every byte, not 0x0A. Try it. Go write a 6502 or x86 program that uses that processor's BCD mode, and then do a hex dump of memory. Or better yet, go get a BCD number, and pass it to the "%x" format specifier in your favorite C compiler (or other language that uses C's format specifiers).

      In this case, one guy is talking BCD, another guy assumed binary, and it was no big deal until 2010 rolled around and 10 suddenly became 16.

      I think you mean to say "one guy is talking BCD, another guy assumed standard binary integer. The "B" in BCD is "Binary" after all... Every number stored in the computer is in one binary format or another. Saying "assumed binary" is roughly the same as "assumed the number was stored in a computer." You have to say which format.

  3. Microsoft by sopssa · · Score: 5, Informative

    Seems Microsoft is supplying some code for EFTPOS machines that is common with Windows Mobile, so it's most likely the same bug in both.

    1. Re:Microsoft by sopssa · · Score: 3, Informative

      Yes they do (almost in every atm actually).

  4. My wireless landline phones all failed 1/1/2010 by Gorobei · · Score: 4, Interesting

    No dial tone, no incoming calls.

    Had to reset the internal datetimes back to 2007, then they started working again. Nice job, Panasonic.

  5. Text messaging from the future by nurhussein · · Score: 3, Funny

    Imagine that, the ability to text to the past. We could get warnings about impending events! New Text Message From Marty McFly: I HV TO TELL U ABT TEH FUTURE Reply from Doc Brown: WHAT? New Text Message From Marty McFly ON THE NIGHT YOU GO BACK, YOU GET SH*message text missing*

  6. 10 hex is 16 decimal by Anonymous Coward · · Score: 5, Informative

    Could be botched string parsing. Could be binary coded decimals interpreted as binary numbers: BCD encodes two decimal digits in the high and low nibbles of a byte. Therefore BCD 10 is 0001 0000 in binary, which is 16 in decimal.

    1. Re:10 hex is 16 decimal by nycguy · · Score: 5, Informative

      This is almost certainly what it is. The year is stored in an SMS message as a two-digit BCD value, according to this spec. (Click on the link for the "timestamp" field.) Some phones must be treating it as a hex field. (Note that most other fields in the SMS message are in hex.)

    2. Re:10 hex is 16 decimal by Posting=!Working · · Score: 3, Interesting

      Can someone tell me what the advantage of swapped nibble encoding are? Other than just being annoying as fuck when you're trying to decode it?
      For those too lazy to read the link , swapped nibble encoding is
      "BCD code where nibbles within octet is swapped. E.g.: 0x31 Represents value of 13"

      So for the format YY MM DD HH MM SS TZ (Time zone in 15 minute increments from GMT) instead of 10 01 03 10 11 43 24 for 2010 Jan 3 10:11:43 time zone 24 (GMT +6) you get the identical data but in the less readable form of 01 10 30 10 11 34 42 (and now it can be confused for 2001 Oct 30 10:11:34 AM. Bonus!)

      It's just complete idiocy to me. Is there some reason you'd want the date/time stamp slightly harder to read?

      --
      This sentence no verb.
    3. Re:10 hex is 16 decimal by Pembers · · Score: 4, Informative

      The specification for the SMS message format pre-dates Y2K by about 15 years. I came across it in 1995 (and thought it was useless - what sort of idiot would try to fit a message into 160 characters? And who would want to type it on a 12-button keyboard?). Where I worked, nobody worried about Y2K until about 1998.

    4. Re:10 hex is 16 decimal by Vintermann · · Score: 3, Funny

      > what sort of idiot would try to fit a message into 160 characters?

      If we find the answer, twitter will finally make sense.

      --
      xkcd is not in the sudoers file. This incident will be reported.
    5. Re:10 hex is 16 decimal by Anonymous Coward · · Score: 4, Informative

      The endianness may make it more sensible. If you have 0x12345678 represented using the correct endianess (the Intel one, not the Sun one), it'll be stored as 0x78563412. Using reverse nibble notation, it'll be 0x87654321.

      But as far as I remember, it is caused by oldold ties to the 4004, which was a 4-bit CPU, inherited via the 8008 and 8080 by the 8086 and 8088.

  7. Official explanation by Anonymous Coward · · Score: 5, Funny

    It's to avoid the world ending in 2012 by skipping straight to 2016. We've left a few years either side of the fateful date as a safety buffer.

  8. Re:Future SMS by CharlyFoxtrot · · Score: 4, Funny

    I did but all they told me was that I talk like a fag and my shit's all retarded.

    --
    If all else fails, immortality can always be assured by spectacular error.
  9. * points finger at Duct Tape Programmers by amn108 · · Score: 5, Funny

    Time to quote Joel (from www.joelonsoftware.com):

    Jamie Zawinski is what I would call a duct-tape programmer. And I say that with a great deal of respect. He is the kind of programmer who is hard at work building the future, and making useful things so that people can do stuff. He is the guy you want on your team building go-carts, because he has two favorite tools: duct tape and WD-40. And he will wield them elegantly even as your go-cart is careening down the hill at a mile a minute. This will happen while other programmers are still at the starting line arguing over whether to use titanium or some kind of space-age composite material that Boeing is using in the 787 Dreamliner.

    When you are done, you might have a messy go-cart, but it’ll sure as hell fly.

    Hey, Jamie! Your proprietary date datatype didn't fly! Would you please turn around and fix it?

    1. Re:* points finger at Duct Tape Programmers by daveime · · Score: 4, Insightful

      Yes, but that's just the point isn't it ?

      There are 10 types of people ...

      1. Those who will make a solution that will work for perhaps 30 or 35 years, because it is "good enough" for the foreseeable future, ala Y2K, 2032 for linux etc ...

      2. Those who will want to do unit tests to see if the date function still works in the year 9500, and won't pass it through QA until it does.

      Now, consider the PHB, when you tell him that solution 1 will be up and running in 5 minutes, whereas solution 2 will be up and running in about 5 years, once the specification has been formalized and ratified by the UN security council.

      Which solution will the PHB choose I wonder ? Programming has always been a compromise, no one *really* expects that something they code today will still be around in 35 or 40 years, it's only occasionally that something *does* survive that long (COBOL legacy systems etc), and come and bite us in the ass when the new millenia arrives.

      Having said that, I wonder how many of the "buzzword" languages we see today will still be around in the next 40 years ? The concept of longevity might have been relevant in the 60's, these days it's more a case of a complete rewrite every year or so.

  10. You could mess with people! by olsmeister · · Score: 3, Funny

    Bob- Happy Nw Yr! What a decade so far. Cubs winning the series, and who would have predicted that the Mayan calendar was really right? Glad I loaded up on all the MSFT back in '10. Are you going to visit your wife's grave next week for the 6th anniversary? kthx!

  11. Re:Future SMS by Runaway1956 · · Score: 4, Funny

    Should have fed them a politician. Al Gore comes to mind.

    Msge to fleet command: Avoid the 3rd rock, the inhabitants taste like shit!

    --
    "Windows is like the faint smell of piss in a subway: it's there, and there's nothing you can do about it." - Charlie Br
  12. Re:WHY DO PEOPLE INSIST UPON REPLACING THE FIRST Z by Chabil+Ha' · · Score: 3, Interesting

    No to mention Y2K was a pun of sorts for shortening 2000 to three bytes from four. Now we're taking more space than the original; Y2K16 vs 2016. Those COBOL programmers would be rolling in their graves.

    --
    We're all hypocrites. We all have hidden parts, it's the contrast between them that make us more a hypocrite than others
  13. no that's a Y210 bug by rubycodez · · Score: 3, Informative

    Y bugs are named for the year in which they occur, not the year they jump....otherwise Y2K would have been Y1.9K, or even better YMCM

  14. Re:WHY DO PEOPLE INSIST UPON REPLACING THE FIRST Z by osu-neko · · Score: 3, Insightful

    Any EE will tell you that 2k16 means 2.16k or 2160. How does this garbage continue making it to the front page?

    Actually, most EE's I know are smarter than that. The fact that X means Y in some contexts does not mean X means Y in all contexts. Most competent speakers of the language have no trouble determining meaning, taking context into account. It's rare that someone manages to get an EE while lacking the level of intelligence required to do that.

    --
    "Convictions are more dangerous enemies of truth than lies."