couple of fixes for protected characters in hash keys