Fixed typos and moved more stuff into lib/util for parsing signed cookie...

...s.