Testing parsing of credential.

Also fixed infinite loop due to extra blank lines.