Remove file IO from the library

The library should operate on an inmemory password database
to avoid dependencies towards other fileformats (and to avoid
race conditions when the file is updated or not)
Fix race condition problems in find_pw

The previous version could cause use of released memory if the
password database changed between the lookup and comparinson
of the memory.