Checks to see if key is valid.
Revert "Checks to see if key is valid."

This reverts commit 8d0e4ac6237282367b374b6683f6276e372d4604.
Checks to see if key contains valid characters.