credential: detect unrepresentable values when parsing urls