optional password caching and extensive logging

Quite some lines have been changed...one pull request adding two features... finding my way in git(hub)..

Bests,

Bram