Ugh. I've been staring at your post for a while wondering about solutions.
I wish there was some way to turn this situation into the bank thanking you with some kind of consideration.
At least it's good to hear that the bank now knows about it, although that doesn't really solve your situation.
I take it that fees are a problem because the contract payouts were stopped, more or less? (As infuriating as that type of situation is) For example I know of one lawyer in NSW who takes computer-related work - for mid-range three figures :/ (that said, would this be interesting to you?)
It sounds to me like it would be a very good idea for you to get a concrete, unambiguous idea (ie sit down and work it out with someone) of where you sit in terms of civil liability, relative to your total and utter ignorance (for example, what's the difference between (a) signing up for this contract, (b) walking into the building for the day and (c) committing the code? IANAL (!!!) but I reckon the argument of intent is equally weak with all examples). It's possible you may be less vulnerable than surface/kneejerk intuition might suggest - but of course I could be wrong. (I have absolutely no idea.)
Besides making it clear to the lawyers about the immediate/current liquidity situation, the bank and ombudsman don't seem completely against you, and I wonder how far you could go with that.
I assume you've reiterated all of the context (without unnecessary details, unless that's okay) with the Ombudsman, to see what ideas they might be able to come up with.
With the bank, you've probably scored a few points with the security and related folks there. If the consulting firm is integrated into the bank then that might point to systemic breakdown elsewhere, but on the other hand, their silence could simply be professionalism on their part while they mete out corporate knuckle sandwiches. (Or I could be being ridiculously optimistic.) Maybe you could chase them down and see if they'd be interested in having you on board; worst (ish) case is that you find more of this kind of thing and get even more points. Something to keep in mind.
Finally, have you tried Legal Aid? They're not lawyers per se, but they may be able to give you a bit of a foundation to headscratch through this with. I would definitely call them. (It's only 3PM!)
As a last resort another contract may turn out to be necessary, and I hope that works out if it comes to that. But don't completely give up, even after that point - you refused to do work that could legally compromise you because it violates corporate policy and standard security access controls, due to the craziness and laziness of others. You should still receive your contract payout.
lol at the perl code bit :)
If you want to get in touch, my email is in my profile, and the username you've picked isn't taken on Gmail yet FWIW; there's really nothing interesting Gmail can leak. Just use a fake name/birthday for the associated G+ account that will get created.