Refactoring: move common functions to upper class
Seed generation based on sha512 and folding added