Commodore and old system LHA archive format...
Collapse
X
-
-
Re: Commodore and old system LHA archive format...
I created some test files while fiddling with the system date.
Code:TEST1 TXT 18 02-21-16 4:50p test1.txt TEST2 TXT 18 02-21-15 4:50p test2.txt C:\Downloads\Software\LHArc>type test1.txt 02-21-2016 4:49 C:\Downloads\Software\LHArc>type test2.txt 02-21-2015 4:49 C:\Downloads\Software\LHArc>debug test.lzh -d 1262:0100 22 25 2D 6C 68 30 2D 12-00 00 00 12 00 00 00 43 "%-lh0-........C 1262:0110 86 55 48 20 01 09 54 45-53 54 31 2E 54 58 54 AB .UH ..TEST1.TXT. 1262:0120 7C 4D 00 00 30 32 2D 32-31 2D 32 30 31 36 20 34 |M..02-21-2016 4 1262:0130 3A 34 39 20 0D 0A 22 5D-2D 6C 68 30 2D 12 00 00 :49 .."]-lh0-... 1262:0140 00 12 00 00 00 58 86 55-46 20 01 09 54 45 53 54 .....X.UF ..TEST 1262:0150 32 2E 54 58 54 BF 8C 4D-00 00 30 32 2D 32 31 2D 2.TXT..M..02-21- 1262:0160 32 30 31 35 20 34 3A 34-39 20 0D 0A 00 2015 4:49 ... 02-21-2016 4:49 -> 0x48558643 = 0b 0100100 0010101011000011001000011 02-21-2015 4:49 -> 0x46558658 = 0b 0100011 0010101011000011001011000 C:\Downloads\Software\LHArc>type test1.txt 02-21-2016 5:05 C:\Downloads\Software\LHArc>type test2.txt 03-21-2016 5:05 C:\Downloads\Software\LHArc>debug test.lzh -d 1262:0100 22 50 2D 6C 68 30 2D 13-00 00 00 13 00 00 00 CA "P-lh0-......... 1262:0110 88 55 48 20 01 09 54 45-53 54 31 2E 54 58 54 FF .UH ..TEST1.TXT. 1262:0120 C8 4D 00 00 30 32 2D 32-31 2D 32 30 31 36 20 35 .M..02-21-2016 5 1262:0130 3A 30 35 20 20 0D 0A 22-9B 2D 6C 68 30 2D 13 00 :05 ..".-lh0-.. 1262:0140 00 00 13 00 00 00 D9 88-75 48 20 01 09 54 45 53 ........uH ..TES 1262:0150 54 32 2E 54 58 54 AE 34-4D 00 00 30 33 2D 32 31 T2.TXT.4M..03-21 1262:0160 2D 32 30 31 36 20 35 3A-30 35 20 20 0D 0A 00 -2016 5:05 ... TEST1 TXT 19 02-21-16 5:06p test1.txt TEST2 TXT 19 03-21-16 5:06p test2.txt
Code:02-21-2016 5:06 -> 0x485588CA = 0b 0100100 0010 10101 1000100011001010 03-21-2016 5:06 -> 0x487588D9 = 0b 0100100 0011 10101 1000100011011001 year mth day time - 1980
-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
-
Re: Commodore and old system LHA archive format...
31BA6B94 --> 06-08-96 11:13pm
30BA 6B94 --> 11-27-95 5:53pm
Number of days from 11-27-95 to 06-08-96 is about 194.
0x31BA6B94 - 0x30BA6B94 = 0x1000000
(194 days) / 0x1000000 = 0.999069214 seconds
Therefore each increment in the date/time dword corresponds to 1 second.
So ...
0x31BA6B94 seconds = 26.4379623 years -> 26th year
0.4379623 years = 5.2555476 months -> 6th month
0.2555476 months = 7.77806394 days -> 8th day
Therefore the date/time appears to be a dword that counts the number of seconds since 1970.
Is this called Epoch time?-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
-
Re: Commodore and old system LHA archive format...
Here is an experiment you could try. Place the following lines in a BAT file and then execute the batch. The result should be a text file with a date/time stamp corresponding to 01-01-1970 0:00.
Code:echo 01-01-1970 | date echo 0:00 | time echo 01-01-1970 0:00 > test.txt type test.txt
Of course you will need to restore your machine's current date and time.
Edit: I just tried it. Apparently DOS doesn't like 1970. It's too early. :-(
What happens if you take your custom archive, replace the date/time bytes with zeros and recalculate the 8-bit checksum? How does your custom software report this date/time stamp?
Code:Offset(h) 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F 00000000 23 39 2D 6C 68 35 2D 7D 9F 02 00 E8 11 05 00 00 #9-lh5-}Ÿ..è.... 00000010 00 00 00 20 01 0A 6A 65 74 62 62 73 2E 65 78 65 ... ..jetbbs.exe 00000020 93 F2 20 00 00
JetSetup.exe (Proprietary software, no source code, extracts files from JetBBS.dat)
JetBBS.dat (Custom archive. I can create custom archives using a modified version of ar from back in the day, but the time / date stamps are just 0000's).
ar (a very old archiving program that was later renamed to lha because the name ar conflicted with another program. I can use this to create archives that JetSetup.exe can decompress, but it cannot create exact archives (the date/time is missing.).
The goal is to use ar to extract the files from JetBBS.dat (I can already do this) and then recreate JetBBS.dat and have it be a 1 to 1 exact copy of the original JetBBS.dat file. The only thing that's off is the time stamp.
When I use ar to create JetBBS.dat, for the time stamp, it uses all 0's. So, to answer your question, when I create a custom JetBBS.dat file and it has four bytes of 0's for the time stamp, JetSetup.exe, running in DOSEmu, creates the files with a time stamp of 12-31-97 4:00PM.-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
-
Re: Commodore and old system LHA archive format...
0F 10 11 12h
00 00 00 01 -> 07-13-98 9:20p
00 00 00 02 -> 01-24-99 12:40a
00 00 00 03 -> 08-06-99 6:00a
00 00 00 10 -> 07-04-06 2:24p
94 00 00 10 -> 07-04-06 2:26p
I don't get the last part there. Could there be a flaw with DOSEMU? I add 94 for the first two bytes and we add two minutes??-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
-
Re: Commodore and old system LHA archive format...
00 01 00 00 -> 12-31-97 4:04p
00 02 00 00 -> 12-31-97 4:08p
00 10 00 00 -> 12-31-97 5:08p (I don't get why the minutes are 08 here)...
I feel like we're getting somewheres...
It's a not a DOSEMU issue or anything. I installed DOS 6.22 in VirtualBox on a Windows box and ran the JetSetup program. It shows the same date / time. 12-31-97 5:08p.-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
-
Re: Commodore and old system LHA archive format...
I mistyped. Been a long day. Thinking of calling it a night. Thank you for correcting me, yes, each hex digit is a nibble (4-bits), two are a byte (8-bits).
Little-Endian means lsf bit stored first, right?
So I should try something like:
10 00 00 00
20 00 00 00
etc?-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
-
Re: Commodore and old system LHA archive format...
Yes, the ar program puts in all 0's and it shows a time of 12-31-97 4:00PM. Why though? Why is the beginning of time Dec 31, 1997 at 4:00PM? Could this maybe be the time the original program was created? I would think time would start in 1980, being an MS-DOS program...-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
-
Re: Commodore and old system LHA archive format...
If you examine the header.c and header.doc files in the packages uploaded by stj, you find that there are two date/time formats -- generic stamp format and Unix format (1/1/1970 0:00).
My DOS tool (LHA255.EXE) uses the former:
Code:/*----------------------------------------------------------------------*/ /* */ /* Generic stamp format: */ /* */ /* 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 */ /* |<-------- year ------->|<- month ->|<-- day -->| */ /* */ /* 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 */ /* |<--- hour --->|<---- minute --->|<- second*2 ->| */ /* */ /*----------------------------------------------------------------------*/
The header.doc and header.c files would suggest that the choice of generic versus Unix time is determined by the "level" byte (byte 0x14). A value of 0x00 or 0x01 selects generic time while a value of 0x02 selects Unix time. There is no mention of any other date/time stamp. In my DOS case and your case the level byte has a value of 0x01, so one would expect that the generic format would be used. Clearly this is not what is happening in your case.Comment
-
Re: Commodore and old system LHA archive format...
Yeah, agreed. It's odd and I wonder what program was actually used to create this "custom" archive. ar is soo close to creating exact duplicates against the original JetBBS.dat file. When I run JetSetup.exe, it even has the same bugs that's in JetSetup.exe (It extracts 119 files but displays the message 119 successfully extracted and then shows two more files that were extracted after the message (even those though two files make up the 119)).
I contacted the original author of ar and he said I can do what I want with the program and that it's the "latest" version that he wrote. He suggested I check out LHA if I wanted something more up to date.
I appreciate all the help. I wonder if maybe Troy modified the program to add a time / date stamp and picked seconds since 1997 instead of using a generic or unix time stamp. I don't think seconds are going to be very efficient.
We're still missing something though. If all 00's are Dec 31, 1997, how come when I use the original JetBBS.dat file, the JetBBS.exe file has a time stamp of 06-08-96 11:13pm, a date that's actually before Dec 31, 1997 4:00pm...
Maybe there's a flag that shows if we count forward or backwards? Some weird going on there.-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
-
Re: Commodore and old system LHA archive format...
I wish I knew more about assembly for x86 CPUs, DOS executables and using debug to step through the program and figure out what's going on by looking at the assembly.Last edited by Spork Schivago; 02-22-2016, 04:23 PM.-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
-
Re: Commodore and old system LHA archive format...
I have Oracle's VirtualBox setup with DOS 6.22 now. I'll try the original and see if it produces the same results as DOSEmu under Linux. I know with all 00's, it's the same results in DOS 6.22 running under VirtualBox as it is for DOSEmu.
It's a real pain getting the files into VirtualBox though. I first have to copy the files to disc and then create a disk image from the 1.44MB floppy disk. Then I can have VirtualBox mount the image. It seems VirtualBox doesn't work with my USB Floppy drive (probably because there's no USB support for DOS). It doesn't work with my thumb drives and because I cannot install OS Additions, I can't do shared folders. I looked into setting up network shares but that seems to require DOS drivers for my wife's wireless NIC. Those things are hard to find!-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
-
Re: Commodore and old system LHA archive format...
I like that idea. I just tried the original JetBBS.dat file on VirtualBox and just like in DOSEmu, the timestamp shows up for JetBBS.exe as: 06-08-96 11:13PM-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
-
Re: Commodore and old system LHA archive format...
I remember what gave me the idea that these were modified LHA archives. I scoured the internet looking for all the JetBBS files I could find. Some of the earlier versions used non-modified LHA archives. Linux identifies these older versions as LHa (2.x) archives.
I wonder if there's any older versions of LHA that had a different time format.-- Law of Expanding Memory: Applications Will Also Expand Until RAM Is FullComment
Related Topics
Collapse
-
This specification for the HP Station de travail Z2 format tour G4 can be useful for upgrading or repairing a desktop PC that is not working. As a community we are working through our specifications to add valuable data like the Station de travail Z2 format tour G4 boardview and Station de travail Z2 format tour G4 schematic. Our users have donated over 1 million documents which are being added to the site. This page will be updated soon with additional information. Alternatively you can request additional help from our users directly on the relevant badcaps forum. Please note that we offer no...09-12-2024, 02:20 PM
-
by piernovJust archiving everything related to bumpgate since most stuff has disappeared from Google. Maybe people will finally take the time to read some of it and stop shouting "reflow gpu" at every occasion but rather try to understand what the real issue is…
Interesting parts about the failure analysis are "Why Nvidia's chips are defective" and "Why Nvidia's duff chips are due to shoddy engineering"
May complete this post at a later date with more details.
Basically issue is a combination of thermal dissipation of the chip with hotspot,... -
by s_henyaHi guys,
Just found this old but nice IMac 2012.
current user had a password which i dont know.
i want to format it and do a clean IOS installation.
i tried command. + R after powering on but it didn’t do anything and IOS continued to load.
i tried the online recovery but it gave me denied icon after connecting to the Wifi.
is there any working method to format it?
guess i can take the long way of ordering the prying tools and format the hdd using another pc.
but i was hoping for another quicker solution.... -
by inflexThis is an important update for ALL the repair community.
For years now the repair industry has suffered to a new class of gatekeeper when it comes to getting our boardviews & schematics, files are being leaked out of factories but only to select groups who then no longer share those files out to the community, locking them up in a proporiatory format with online-only access.
The XZZ PCB file format has now been reverse engineered and you can now read those .pcb files in FlexBV, free, demo and licenced edtiions.
https://pldaniels.com/flexbv5
... -
by inflexThere's file format called "Teboview" with an extension .tvw, and I've noticed some Lenovo laptop boards are using it.
I would like to write a decoder for the format for OpenBoardview but thus far, naturally, I've not found any useful specification on the internet. I've downloaded TeboView-ICT but unfortunately it also doesn't provide a lot of information about the technical information for each part/net/etc.
I've decoded a moderate amount of the file format but I would *really* appreciate it if anyone could drop a file format spec accidentally
...-
Channel: Schematic Requests ONLY!
-
- Loading...
- No more items.
Comment