now with hashfun and getkeyfun included
m