views:

60

answers:

1

I've inherited a Visual Basic 6 application that accesses a database directly, and I intend to rewrite it in Java.
However, something I NEED is the database user+password, which I believe is hard-coded into the application's source.
Unfortunately, I don't have access to it's source.

How could I retrieve the DB password? Is there a way to de-compile VB6 into some half-understandable form at least? or should I just log on and sniff it from my own PC?

+2  A: 

I'd agree with MicSim that the DBA would be the person to ask.

However if you want to hack in to the source, you might have some luck just opening up the DLL (or EXE? OCX?) in a hex/text-editor and having a look through. If the credentials are really hard-coded into the application, presumably they're stored as strings... and I've noticed that strings tend to get stored in the assemblies created by VB6 in clear text.

Gavin Schultz-Ohkubo
But how would I find it though dozens of lines of code? :/
Hugo
It was never going to be easy.
Gavin Schultz-Ohkubo
been there - done that - I created a script for my editor that removes all characters outside of the range from space to tilda. The results are all printable characters as pure text. Any strings will show up at this point.
Dave