Merge pull request #8 from Ravenstine/keygen

javascript sends length of message to server and server creates private ...
small refactor