Unicode Encode Error

I would like to issue an SSL certificate for new domains and get this error:
An unexpected error occurred:
UnicodeEncodeError: ‘ascii’ codec can’t encode character u’\xe4’ in position 190: ordinal not in range(128)
Please see the logfiles in /var/log/letsencrypt for more details.
letsencrypt.txt (45.5 KB)

command: certbot certonly --cert-name rukotuerk -d rukoturkiye.com,ruko.com.tr,www.ruko.com.tr,www.rukoturkiye.com,xn--rukotrkiye-eeb.com,www.xn--rukotrkiye-eeb.com

Domains: rukoturkiye.com, ruko.com.tr, www.ruko.com.tr, www.rukoturkiye.com, rukotürkiye.com, www.rukotürkiye.com

Hi @sebseb

\xe4 is an ä. Check your config- and server files if you have that ä somewhere.

Which configfile and which serverfiles do you mean?

The help template is here to help people help you. By not following it, you are making harder to see your problems. I have looked in the trace file and it shows

certbot version: 0.10.2

this is too old. This use a protocol version that has been found to be vulnerable and has been replaced.

Attempting to parse the version 0.35.1 renewal configuration file found at /etc/letsencrypt/renewal/ruko.me.conf with version 0.10.2 of Certbot.

You have also installed certbot-auto but not removed the outdated version. So the 2 versions are fighting each other. You are very probably also using an outdated operating system too - my guess is Debian 8.
So try sudo apt-get remove certbot

1 Like

There you use ü.

All Certbot may check - /etc/letsencrypt/renewal and your vHost config files.

in these configs is no ü.
I assume that there is no ü because the certificates are not created for this domaisn

Your error is an “ä”, not “ü”. But your “ü” says: You use non-ascii characters.

I can not find an ä ore an ü

I think @JuergenAuer made an assumption that the file was encoded using a character set like ISO 8859-1, but it could have been encoded using a different character set, in which case the offending character could be something different from ä. If your file contains text and comments in Turkish, for example, it could be any of the letters çğıöşü which occur in the Turkish alphabet but not in the ASCII character set.

You could use a command like

grep -r -P "[^\x00-\x7F]" /etc/apache2

to locate any non-ASCII characters in this web server configuration file.

It’s also possible that upgrading to a newer version of Certbot will help with some configuration file parsing problems, as indicated by @gpatel-fr (if you have certbot-auto, you have to explicitly run it as ./certbot-auto rather than certbot in order to get the benefit of the automatic installer).

1 Like

Not exactly. I’ve checked hex e4 = integer 228, that’s the unicode codepoint of “ä”.

But I see, that’s wrong. Because if the file is used with another (system specific) ISO-8859 encoding, there are other unicode code points possible.

So my idea to find the character is wrong. I can find only one character.

Solution? First, we should ask: “What’s your standard ISO-8859 - encoding?”

I see. More to the point here, if the underlying file is encoded in UTF-8 or something, the individual byte e4 could potentially be part of various different multibyte characters. :slight_smile:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.