Re: Date bug.
From: Bianca (blah_at_no.mail)
Date: 12/23/04
- Next message: vipindeep: "Need some programs for dynamic analysis"
- Previous message: CTips: "Re: Does software-engineering focus on the wrong subject?"
- In reply to: Dave: "Re: Date bug."
- Next in thread: pete_at_nospam.demon.co.uk: "Re: Date bug."
- Reply: pete_at_nospam.demon.co.uk: "Re: Date bug."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 23 Dec 2004 12:18:12 +0800
Dave <recneps.w.divad@elcaro.moc> schreef in berichtnieuws
qBbyd.5$Tg5.65@news.oracle.com...
>
>
> Bianca wrote:
> > Got an old dos proggy (exe file, no source av), problem there is if current
date
> > is given, it gives an error message that the date must be between 1974 and
1999.
> >
> > So, the exe file need to be modified, somewhere...
> >
> > Any hints how that part of the code that does the date check can look like?
> > As for now it is all abracadabra since it is not in plain text.
>
>
> Simple. Find the error message in the string table, then find the
> pointer to that string in the code. Work backwards from the pointer and
> find the test that causes the pointer to be dereferenced. The test
> could be a number of things - a string compare, a less-than, a
> less-than-or-equal, and it could be comparing 1999, 2000, 99 or a few
> other possibilities. If it's a less-than, simply change the value it's
> comparing and that should stop the error appearing.
>
> The check probably prevents some bugs in date calculations further down
> the code though. It'll be a bit harder to fix those bugs.
>
> Although you say "no source", in fact you can get source from it - just
> disassemble it and you'll have assembly source. Assembly is a bit
> harder than most 3GLs/4GLs, but it's not impossible. Plus there's a
> good chance the program won't be longer than a few hundred K, so that
> should help.
>
> You might find OllyDbg useful.
>
> Dave.
Tnx for reply.
OllyDbg seems usefull, but, it is no 32bit so Olly does not load the proggy...
Phew, glad it's simple!
Found in a normal editor the error message, the digits of the year are showed as
'%s' with in front of that line some address 00035something.
How can I disassemble it (what prog?), and bring it back to a normal (and
working) *.exe file?
Newbie question: what's 3GLs/4GLs ?
Reply to the hint to change the date on the system is no option...
The date is printed, so I still get a wacko date on the form.
;o)
- Next message: vipindeep: "Need some programs for dynamic analysis"
- Previous message: CTips: "Re: Does software-engineering focus on the wrong subject?"
- In reply to: Dave: "Re: Date bug."
- Next in thread: pete_at_nospam.demon.co.uk: "Re: Date bug."
- Reply: pete_at_nospam.demon.co.uk: "Re: Date bug."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|