2021-11-08 Fred Gleason <fredg@paravelsystems.com>

* Fixed a bug in the rdxport.cgi service that caused XML output
	to be encoded with the incorrect character set.

Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
Fred Gleason
2021-11-08 16:46:45 -05:00
parent 0152cd357b
commit 5226c7c926
13 changed files with 45 additions and 39 deletions

View File

@@ -408,12 +408,12 @@ void Xport::TryCreateTicket(const QString &name)
QDateTime expire_datetime;
if(rda->user()->createTicket(&ticket,&expire_datetime,
xport_post->clientAddress(),now)) {
printf("Content-type: application/xml\n\n");
printf("Content-type: application/xml; charset=utf-8\n\n");
printf("<?xml version=\"1.0\" encoding=\"UTF-8\" ?>\n");
printf("<ticketInfo>\n");
printf(" %s\n",RDXmlField("ticket",ticket).toUtf8().constData());
printf(" %s\n",
(const char *)RDXmlField("expires",expire_datetime).toUtf8());
RDXmlField("expires",expire_datetime).toUtf8().constData());
printf("</ticketInfo>\n");
exit(0);
}