Overclockers Australia Forums
OCAU News - Wiki - PC Database - QuickLinks - Pix - Sponsors  

Go Back   Overclockers Australia Forums > Software Topics > Programming and Software Development


Sign up for a free OCAU account and this ad will go away!
Search our forums with Google:
Reply
 
Thread Tools
Old 3rd January 2010, 8:30 PM   #1
yoink Thread Starter
Member
 
yoink's Avatar
 
Join Date: Feb 2002
Posts: 2,837
Default Y2.01K bug

Most of you have probably seen the news about the "new y2k" bug, as seen here. Note also comment 11 on that page:

Quote:
my Navman PiN device suddenly said the date was 01/01/2016 and not 01/01/2010
Somewhere there is probably a common date library that calculates the date incorrectly - it is not a coincidence that "010110" = 16 converted from binary to hex

Anyone got any ideas what library it may be? So far the following devices / services have been affected:

I think the Navman runs on windows mobile 2003? Obviously Exchange runs on windows, but I'm not sure that it is not the pre-s fault.

Anyway, if you find any other devices / services that have this issue, let me know, and I'll list them here; this could be rather big by tomorrow, when everyone gets back to work...
__________________
Over 200 trades and counting!

BatteryFree Mouse! Where is your avatar? Fake Memory Cards Paxjs vobiscum!

Last edited by yoink; 6th January 2010 at 11:47 AM. Reason: Added symantec bug
yoink is offline   Reply With Quote
Old 4th January 2010, 10:44 AM   #2
yoink Thread Starter
Member
 
yoink's Avatar
 
Join Date: Feb 2002
Posts: 2,837
Default

Discussion on slashdot here, consensus for the SMS bug seems to be that some phones are treating the timestamp as hex rather than a two-digit BCD value as per the spec. This is most likely similar to what has happened to other devices too...

Edit: this thread blames it on "Swapped Nibbles", and confusion about endianness, can someone more knowledgeable about this issue comment?
__________________
Over 200 trades and counting!

BatteryFree Mouse! Where is your avatar? Fake Memory Cards Paxjs vobiscum!

Last edited by yoink; 4th January 2010 at 10:49 AM.
yoink is offline   Reply With Quote
Old 4th January 2010, 12:43 PM   #3
0restes
(Banned or Deleted)
 
Join Date: Sep 2009
Posts: 1,481
Default

The irony of your avatar does not escape me.
0restes is offline   Reply With Quote
Old 4th January 2010, 2:44 PM   #4
mikeyyy
Member
 
mikeyyy's Avatar
 
Join Date: Apr 2005
Location: Sydney
Posts: 530
Default

I skimmed over it, but it seems that for the SMS one, apparently the spec says the year is sent as one byte encoded in BCD.

The upper 4 bits represent the 1's digit, and the lower 4 bits represents the 10's digit. The year is stored only as 1 byte, apparently because the SMS format pre-dates Y2K and the century is inferred by the date set on the phone. So you set the date to be 2005, and the year part that is sent is simply the 05, no mention of the 20.

This is sent in BCD as 0x50, taking the 20 from the year on the phone, and read 0x50 as 05, you get 2005.

This is where I get confused, if the above is true, then the date for 2010 *should* be represented as 0x01. In their BCD encoding this means 10, but in hex it means 1. Which would give 2001, not the 2016 they're getting.

You mentioned a confusion over endianness, which usually means the order bytes are stored, but in this case maybe the order of the 4-bit chunks (or nibbles) are stored. If you read 0x10 as 10 and not 01, opposite to the spec, then 0x10 should be 10 in BCD, or 16 in hex.

If the phone SMS software treats the byte as a hex number, it'll print 2016. If it was properly treated as BCD, technically it should be 2001, that is if the spec I found linked on your sites is the right one. If that spec is wrong, and 0x10 does mean 10 and not 01, then all makes sense...

The spec linked was http://www.dreamfabric.com/sms/scts.html, and if you follow the example, you'll see each byte is read in reverse to get the numbers out.
__________________

Successful trades with: natorsom, WanGa, technoir, wahoo84, yangby, OverPAQ'd, davep, Falls, GenerAsianX, Jm3, mr_nguyen, lui_gough, Jobe, vlcalaisv8, K3nii, Thrawn, SLATYE, RILEYP, anf3h, charithjperera

Last edited by mikeyyy; 4th January 2010 at 2:46 PM.
mikeyyy is offline   Reply With Quote
Old 6th January 2010, 6:45 AM   #5
Fishmaster
Member
 
Fishmaster's Avatar
 
Join Date: Oct 2006
Location: Sydney, 2119
Posts: 1,077
Default

Anyone seen any other areas its messing up? We've been watching some of our older programs for any bugs or mess ups but nothing sofar, seems to be only hitting SMS and ATM's.
Fishmaster is offline   Reply With Quote
Old 6th January 2010, 9:23 AM   #6
yoink Thread Starter
Member
 
yoink's Avatar
 
Join Date: Feb 2002
Posts: 2,837
Default

Quote:
Originally Posted by 0restes View Post
The irony of your avatar does not escape me.


Quote:
Originally Posted by mikeyyy View Post
<techinal explanation>
Thanks for that, makes a bit more sense

Quote:
Originally Posted by Fishmaster View Post
Anyone seen any other areas its messing up? We've been watching some of our older programs for any bugs or mess ups but nothing sofar, seems to be only hitting SMS and ATM's.
Check this out: 30 million bank cards hit by 2010 bug

Excerpt:
Quote:
AROUND 30 million high-tech German bank cards could leave owners high and dry, bank associations warned as the feared Y2K computer bug struck 10 years later than expected.

The problem that hit cardholders trying to use cash machines or make payments throughout Germany and abroad stems from computer chips unable to recognise the year 2010, and could take up to a week to resolve, the DSGV savings and regional banking association said in a statement.
I love how they blame the "Y2K computer bug", it's a "date miscalculation" at best...
__________________
Over 200 trades and counting!

BatteryFree Mouse! Where is your avatar? Fake Memory Cards Paxjs vobiscum!
yoink is offline   Reply With Quote
Old 6th January 2010, 11:28 AM   #7
houseofzeus
Member
 
Join Date: Mar 2005
Location: St. Lucia, Brisbane
Posts: 2,442
Default

Quote:
Originally Posted by yoink View Post

I love how they blame the "Y2K computer bug", it's a "date miscalculation" at best...
Realistically in most cases it's going to be a miscalculation introduced as a result of the original attempts to fix/workaround Y2K so it's not that far off the mark.
houseofzeus is offline   Reply With Quote
Old 6th January 2010, 11:32 AM   #8
yoink Thread Starter
Member
 
yoink's Avatar
 
Join Date: Feb 2002
Posts: 2,837
Default

Quote:
Originally Posted by houseofzeus View Post
Realistically in most cases it's going to be a miscalculation introduced as a result of the original attempts to fix/workaround Y2K so it's not that far off the mark.
I doubt it - the SMS spec was around before Y2K, and the y2k issue is not really related to this problem. I think it is more of a case of the media trying to compare the problem back to something that people can relate to.
__________________
Over 200 trades and counting!

BatteryFree Mouse! Where is your avatar? Fake Memory Cards Paxjs vobiscum!
yoink is offline   Reply With Quote
Old 6th January 2010, 11:34 AM   #9
Tekin
Member
 
Tekin's Avatar
 
Join Date: Nov 2002
Location: Elsewhere.
Posts: 2,811
Default

http://www.theregister.co.uk/2010/01...tec_y2k10_bug/

this one is of relatively minor impact - but still rather entertaining.
__________________
Crap Joke for the Week:
Q: What do you get when you cross Dracula with a used car dealer?

A: Autoexec.bat

-- Thinkgeek Fortunes

Last edited by Tekin; 6th January 2010 at 11:37 AM.
Tekin is offline   Reply With Quote
Old 6th January 2010, 11:46 AM   #10
MrSnuffy
Member
 
MrSnuffy's Avatar
 
Join Date: Jun 2001
Location: Hobart
Posts: 1,167
Default

The SpamAssassin one was a little more 'duh' (and was admittedly fixed last year... but who deploys patches, really?!)

If $date > 2010 : then "too far into future, must be spam"

heh.
MrSnuffy is offline   Reply With Quote
Old 6th January 2010, 11:48 AM   #11
yoink Thread Starter
Member
 
yoink's Avatar
 
Join Date: Feb 2002
Posts: 2,837
Default

Quote:
Originally Posted by Tekin View Post
http://www.theregister.co.uk/2010/01...tec_y2k10_bug/

this one is of relatively minor impact - but still rather entertaining.
Nice one! - I wouldn't call not getting AV updates minor, that's rather bad actually...
__________________
Over 200 trades and counting!

BatteryFree Mouse! Where is your avatar? Fake Memory Cards Paxjs vobiscum!
yoink is offline   Reply With Quote
Old 6th January 2010, 1:50 PM   #12
houseofzeus
Member
 
Join Date: Mar 2005
Location: St. Lucia, Brisbane
Posts: 2,442
Default

Quote:
Originally Posted by yoink View Post
I doubt it - the SMS spec was around before Y2K.
Which accounts for one out of a growing list of systems encountering problems. I'm not saying it *is* the Y2K problem, just I don't think it's that unreasonable for the media to be referring to it this way given there appears to be a link in at least some cases.
houseofzeus is offline   Reply With Quote
Old 6th January 2010, 2:04 PM   #13
Tekin
Member
 
Tekin's Avatar
 
Join Date: Nov 2002
Location: Elsewhere.
Posts: 2,811
Default

Quote:
Originally Posted by yoink View Post
Nice one! - I wouldn't call not getting AV updates minor, that's rather bad actually...
Nah - the updates are still coming through, but they are just force dating them all to be 31/12/2009.

So far we've received 3 updates on the same date. from R113-R116 all dated 31/12/2009
__________________
Crap Joke for the Week:
Q: What do you get when you cross Dracula with a used car dealer?

A: Autoexec.bat

-- Thinkgeek Fortunes
Tekin is offline   Reply With Quote
Old 12th January 2010, 12:24 AM   #14
Foliage
Member
 
Foliage's Avatar
 
Join Date: Jan 2002
Location: Sleepwithyourdadelaide
Posts: 11,004
Default

Sounds like a simple BCD -> hex conversion going wrong. I've done this countless times when writing real time clock routines for PIC microprocessors. Usually because I'm lazy and guess without actually working it out on paper before hand, then when it goes wrong I shotgun debug, the difference here is I actually unit tested my date and time stamps to make sure they were correct in the end.

Shouldn't be too hard to fix.
__________________
Quote:
The true beauty of a self-inquiring sentient universe is lost on those who elect to walk the intellectually vacuous path of comfortable paranoid fantasies.
Foliage is offline   Reply With Quote
Old 12th January 2010, 2:52 PM   #15
chancey
Member
 
Join Date: Jan 2005
Location: Sydney
Posts: 1,335
Default

Quote:
Originally Posted by yoink View Post
Most of you have probably seen the news about the "new y2k" bug, as seen here. Note also comment 11 on that page:



Somewhere there is probably a common date library that calculates the date incorrectly - it is not a coincidence that "010110" = 16 converted from binary to hex

Anyone got any ideas what library it may be? So far the following devices / services have been affected:

I think the Navman runs on windows mobile 2003? Obviously Exchange runs on windows, but I'm not sure that it is not the pre-s fault.

Anyway, if you find any other devices / services that have this issue, let me know, and I'll list them here; this could be rather big by tomorrow, when everyone gets back to work...
I like the irony that everyone was so scared about planes crashing and missiles going off with the Y2K bug and nothing happened, then it hit us 10 years later.
__________________
MusicBrainz AutoEditor | Last.fm: chancey (160,000+ plays)
Laptop: Unibody MacBook 2.4ghz, 4GB DDR3, 750GB
Desktop: Mac Pro (8-core) 2.8Ghz, 6GB ECC RAM, 4x Gigabit
Server: Q9550, 4GB 1066Mhz, 3ware 9650SE-16ML, 12.8 TB, Fedora 10 x64, 4x Gigabit
chancey is offline   Reply With Quote
Reply

Bookmarks

Sign up for a free OCAU account and this ad will go away!

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +10. The time now is 4:54 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd. -
OCAU is not responsible for the content of individual messages posted by others.
Other content copyright Overclockers Australia.
OCAU is hosted by Internode!