Then the company should have had a policy that those passwords be recorded somewhere. If the people in IT failed to enact such a policy, they failed to do their job properly.
I'm a sysadmin - trust and reputation are everything, and I would never *screw* an ex-employer, for any reason, but seriously - if I came in one day and found out I was fired and treated like shit (this has nothing to do with the case at hand - just an thought exercise) - I'd probably think twice before handing everything over.... then I'd hand it over.
In reality, though, if I was fired, I'd suggest to management, even providing a list, of all my accounts and insist that all my passwords were revoked and/or changed, with written confirmation from the company, as soon as possible, just so that I could not be later blamed for someone else's screwup from that point onwards.
I would NOT use any *access* passwords that only existed in my head (which I avoid anyway) as leverage for anything else. That's morally wrong.