I submit that the best approach for dealing with a legacy application is to Leave It The Fuck Alone. (LITFA) Don't extend them. Don't try to understand their inner workings any more than you have to to meet business needs. Just Don't. Leave it the fuck alone. You can keep them running a long long time, generating revenue, while you plan out replacement greenfield apps for the time when you really honestly do need them.
If you have a problem with it, fix it and document the solution. It will happen again. Put a little extra time in and fix it a little better this time, updating the documentation. Over time you will come to understand its behavior. Under no circumstances make any major changes to it. Keep everything tiny and fix exactly one thing at a time.
Refactoring legacy apps is good in one and only one situation, you've got massive amounts of money riding on it, enough so that it's worth doing everything right.