Special characters encoding issue

Moderator: crythias

Post Reply
SylvainL
Znuny newbie
Posts: 2
Joined: 15 Jul 2025, 09:34
Znuny Version: 6.5
Real Name: Sylvain

Special characters encoding issue

Post by SylvainL »

Hello everyone,

When Znuny sends an e-mail containing special characters (such as “é”, “à”), the Subject header is MIME encoded (e.g. =?UTF-8?Q?...?=).
The problem is that Znuny does not seem to expose, via the interface or system configuration, the options for controlling the MIME encoding of headers (particularly Subject).
The code that generates these MIME entities is internal and cannot be configured without directly modifying the Perl modules responsible for sending e-mails.

Is there an existing solution to solve this problem? This creates problem for our French speaking users and would be great solving

Thanks!
root
Administrator
Posts: 4255
Joined: 18 Dec 2007, 12:23
Znuny Version: Znuny and Znuny LTS
Real Name: Roy Kaldung
Company: Znuny
Contact:

Re: Special characters encoding issue

Post by root »

Hello,

What exactly do you want to control regarding the MIME encoding?

- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO

Use a test system - always.

Do you need professional services? Check out https://www.znuny.com/

Do you want to contribute or want to know where it goes ?
SylvainL
Znuny newbie
Posts: 2
Joined: 15 Jul 2025, 09:34
Znuny Version: 6.5
Real Name: Sylvain

Re: Special characters encoding issue

Post by SylvainL »

To explain further:

We’re currently using Znuny 6.5 and sending email notifications where the Subject line contains special UTF-8 characters (for example: é, è, à, ü). These characters are automatically MIME-encoded by Znuny (as per RFC 2047), resulting in Subject headers like this:
Subject: =?UTF-8?Q?R=E9clamation_client_-_Incident_N=BA_1234?=
This encoding is technically correct and standards-compliant. However, we are integrating Znuny with ServiceNow, which does not correctly decode these MIME-encoded headers. As a result, Subject lines in ServiceNow appear garbled or as raw MIME text instead of being human-readable.

What we’re trying to do:

Ideally, we want to prevent the Subject line from being MIME-encoded and instead send it as raw UTF-8 in the header, like:
Subject: Réclamation client - Incident Nº 1234
We understand this would violate the email specification (since headers are expected to be ASCII-only), but in this particular case, we’re trying to find a practical solution that works with a non-RFC-compliant system on the receiving end (ServiceNow).

What we’re asking:
Is there a supported way in Znuny to control or disable the MIME encoding of header fields like Subject?
Or alternatively, is it possible to add a custom header (e.g., X-UTF8-Subject) with the original UTF-8 Subject string, which we can then have ServiceNow read instead of the standard Subject?

We’re not modifying any core Perl modules or MIME libraries, so we’re looking for a solution that works within Znuny’s supported configuration or via extensibility (e.g., PostMaster filters, EventModules, etc.).
root
Administrator
Posts: 4255
Joined: 18 Dec 2007, 12:23
Znuny Version: Znuny and Znuny LTS
Real Name: Roy Kaldung
Company: Znuny
Contact:

Re: Special characters encoding issue

Post by root »

Hello,

It sounds like you want to connect to ServiceNow via email. I would rather move to use the GenericInterface; this is one way to prevent the MIME encoded subject line.

- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO

Use a test system - always.

Do you need professional services? Check out https://www.znuny.com/

Do you want to contribute or want to know where it goes ?
Post Reply