Page MenuHomePhabricator

Cannot upload SVG saved in Dia: "Cannot upload SVG files that contain a non-standard DTD declaration."
Closed, ResolvedPublic

Description

Attempting to upload an SVG file exported by dia produces the following message.

Cannot upload SVG files that contain a non-standard DTD declaration.

Sample file attached.

Event Timeline

Aklapper renamed this task from SVG whitelist blackballs SVG uploads from dia to Cannot upload SVG saved in Dia: "Cannot upload SVG files that contain a non-standard DTD declaration.".Jun 26 2017, 1:02 PM
Aklapper added a project: MediaWiki-Uploading.
dr0ptp4kt triaged this task as Medium priority.Jun 26 2017, 3:15 PM
dr0ptp4kt moved this task from Untriaged to Next up on the Multimedia board.

MediaWiki accepts the following DTD declarations: (from UploadBase::checkSvgExternalDTD())

Your document is using:

This appears to be an earlier draft of the SVG DTD declaration. Why is Dia using this instead of the final one?

I think its fine to whitelist that decleration too

Change 361668 had a related patch set uploaded (by Matthias Mullie; owner: Matthias Mullie):
[mediawiki/core@master] Allow SVGs using an older proposed recommendation DTD

https://gerrit.wikimedia.org/r/361668

We could allow this DTD, but can anyone check if this DTD is still used in recent Dia versions (@Dendrite.sysex?)?
If not, we should probably inform them. (for some reason, I can't get Dia running on my machine)

matthiasmullie lowered the priority of this task from Medium to Low.Jun 27 2017, 1:54 PM
matthiasmullie moved this task from Next up to Needs code review on the Multimedia board.

We could allow this DTD, but can anyone check if this DTD is still used in recent Dia versions (@Dendrite.sysex?)?

Looks like: https://git.gnome.org/browse/dia/tree/plug-ins/svg/render_svg.c#n264 (and no real development in the last 30 months).

If not, we should probably inform them. (for some reason, I can't get Dia running on my machine)

Done: https://bugzilla.gnome.org/show_bug.cgi?id=784253

Change 361668 merged by Brian Wolff:
[mediawiki/core@master] Allow SVGs using an older proposed recommendation DTD

https://gerrit.wikimedia.org/r/361668

Krinkle assigned this task to Bawolff.

Change 365077 had a related patch set uploaded (by Brian Wolff; owner: Matthias Mullie):
[mediawiki/core@REL1_29] Allow SVGs using an older proposed recommendation DTD

https://gerrit.wikimedia.org/r/365077

Change 365077 merged by jenkins-bot:
[mediawiki/core@REL1_29] Allow SVGs using an older proposed recommendation DTD

https://gerrit.wikimedia.org/r/365077

Change 365552 had a related patch set uploaded (by Brian Wolff; owner: Matthias Mullie):
[mediawiki/core@REL1_28] Allow SVGs using an older proposed recommendation DTD

https://gerrit.wikimedia.org/r/365552

Change 365553 had a related patch set uploaded (by Brian Wolff; owner: Matthias Mullie):
[mediawiki/core@REL1_27] Allow SVGs using an older proposed recommendation DTD

https://gerrit.wikimedia.org/r/365553

Change 365552 merged by jenkins-bot:
[mediawiki/core@REL1_28] Allow SVGs using an older proposed recommendation DTD

https://gerrit.wikimedia.org/r/365552

Change 365553 merged by jenkins-bot:
[mediawiki/core@REL1_27] Allow SVGs using an older proposed recommendation DTD

https://gerrit.wikimedia.org/r/365553