how to parse the binary stream in the time zone in the windows registry

  • Thread starter Thread starter Absalom
  • Start date Start date
A

Absalom

I am working with the time zones from the registry

Path (local machine) - "SOFTWARE\Microsoft\Windows
NT\CurrentVersion\Time Zones"

I want to parse the TZI section in order to get the bias and the date
of the daylight saving of various time zones.
can you explain how to parse the binary stream.

thanks
absalom
 
According to this article
http://www.pcmag.com/article2/0,1895,1166624,00.asp
the structure of the registry key is

typedef struct

{
LONG Bias ;
LONG StandardBias ;
LONG DaylightBias ;
SYSTEMTIME StandardDate ;
SYSTEMTIME DaylightDate ;
} TZI ;

where the structure SYSTEMTIME is

typedef struct _SYSTEMTIME {
WORD wYear;
WORD wMonth;
WORD wDayOfWeek;
WORD wDay;
WORD wHour;
WORD wMinute;
WORD wSecond;
WORD wMilliseconds;
} SYSTEMTIME;

( http://msdn2.microsoft.com/en-us/library/tc6fd5zs.aspx )

So the first 4 bytes of the entry would represent the Bias and the last 16
the Daylight date

--
Jon

A word is enough to the wise

I was more than a little surprised to hear the following from "Absalom"
 
Back
Top