This normative appendix registers three media types for MathML, "application/mathml+xml", "application/mathml-presentation+xml" and "application/mathml-content+xml", in conformance with [RFC4288] and W3CRegMedia. The media-types have been approved by IESG for registration with IANA as announced by IETF and are visible on the list of application media-types.
MathML contains two distinct vocabularies. Presentation markup is
for encoding visual presentation, and consists of the elements defined
in Chapter 3 Presentation Markup. Content markup is for encoding
mathematical meaning, and consists of the elements defined in Chapter 4 Content Markup. In addition, both the presentation and content
vocabularies contain the math
, semantics
,
annotation
and annotation-xml
elements. The MathML
media types should be used as follows:
Some MathML applications may import and export only one of these two vocabularies, while others may produce and consume each in a different way, and still others may process both without any distinction between the two. Internally, many MathML processors favor one vocabulary, and support the other vocabulary via conversion if at all. For example, computational software typically favors content markup while typesetting software generally favors presentation markup. By using separate media types for MathML instances consisting solely of presentation or solely of content markup, such processors can conduct negotiation for MathML representations in the preferred vocabulary. For example, consider two web services offering mathematical computation services such as a spreadsheet and a computer algebra system. Internally both prefer content markup, but by default, both generate presentation markup for output. In the absence of media type negotiation, a likely scenario for an exchange between two systems involves two conversions, content to presentation and back again. With negotiation, the conversions are eliminated. Similarly, a client with a MathML instance in one of the vocabularies might seek a web service that preferred that vocabulary.
MathML is commonly used in compound document settings, e.g. within HTML, where content is drawn from a variety of sources, and processed with multiple tools. In these cases, the composition of MathML expressions generally is not known or at least cannot be guaranteed by a user agent. Consequently, the "application/mathml+xml" type should be used, as it may be applied to any valid MathML expression. Since most applications involve data from untrusted sources, "application/mathml+xml" will commonly be appropriate to use as a default type, and all MathML processors are encouraged to accept it as a fallback to the more specific formats.
The media types described here may be applied to instances of all versions of MathML up to and including MathML 3. MathML instances do not contain version numbers, so processors and producers must follow the normative backward compatibility behavior described in this specification.
This registration has been submitted to community review and has been approved by IESG for registration with IANA.
application
mathml+xml
charset
parameter of
application/xml as specified in [RFC3023]As with other XML types and as noted in [RFC3023] section 10, repeated expansion of maliciously constructed XML entities can be used to consume large amounts of memory, which may cause XML processors in constrained environments to fail.
Several MathML elements may cause arbitrary URIs to be referenced. In this case, the security issues of [RFC3986], section 7, should be considered.
In common with HTML, MathML documents may reference external media such as images, style sheets, and scripting languages. Scripting languages are executable content. In this case, the security considerations in the Media Type registrations for those formats shall apply. Similarly, MathML annotation elements may contain content intended for execution or processing. In the case where the processor recognizes and processes the additional content, or where further processing of that content is dispatched to other processors, additional security issues potentially arise. Since the normative semantics of this specification do not require processing of annotation elements, such issues fall outside the domain of this registration document.
MathML may be used to describe mathematical expressions intended for evaluation in computing systems. Because of the nature of mathematics, a seemingly innocuous expression may lead to a computation which does not terminate or is impractically large. This introduces the risk that computational processors in constrained environments may fail.
In addition, because of the extensibility features for MathML and of XML in general, it is possible that "application/mathml+xml" may describe content that has security implications beyond those described here. However, if the processor follows only the normative semantics of this specification, this content will be outside the MathML namespace and shall be ignored.
This specification describes processing semantics that dictate behavior that must be followed when dealing with, among other things, unrecognized elements and attributes, both in the MathML namespace and in other namespaces.
Because MathML is extensible, conformant "application/mathml+xml" processors must expect that content received is well-formed XML, but it cannot be guaranteed that the content is valid to a particular DTD or Schema or that the processor will recognize all of the elements and attributes in the document.
MathML instances do not contain version numbers, so processors and producers must follow the normative backward compatibility behavior described in this specification.
In computational contexts, the result of evaluating a MathML expression is system-specific, and is not guaranteed to be interoperable between systems.
.mml
MathML
public.mathml
conforming to public.xml
This registration has been submitted to community review and has been approved by IESG for registration with IANA.
application
mathml-presentation+xml
charset
parameter of
application/xml as specified in [RFC3023]As with other XML types and as noted in [RFC3023] section 10, repeated expansion of maliciously constructed XML entities can be used to consume large amounts of memory, which may cause XML processors in constrained environments to fail.
Several MathML elements may cause arbitrary URIs to be referenced. In this case, the security issues of [RFC3986], section 7, should be considered.
In common with HTML, MathML documents may reference external media such as images, style sheets, and scripting languages. Scripting languages are executable content. In this case, the security considerations in the Media Type registrations for those formats shall apply. Similarly, MathML annotation elements may contain content intended for execution or processing. In the case where the processor recognizes and processes the additional content, or where further processing of that content is dispatched to other processors, additional security issues potentially arise. Since the normative semantics of this specification do not require processing of annotation elements, such issues fall outside the domain of this registration document.
MathML may be used to describe mathematical expressions intended for evaluation in computing systems. Because of the nature of mathematics, a seemingly innocuous expression may lead to a computation which does not terminate or is impractically large. This introduces the risk that computational processors in constrained environments may fail.
In addition, because of the extensibility features for MathML and of XML in general, it is possible that "application/mathml-presentation+xml" may describe content that has security implications beyond those described here. However, if the processor follows only the normative semantics of this specification, this content will be outside the MathML namespace and shall be ignored.
This specification describes processing semantics that dictate behavior that must be followed when dealing with, among other things, unrecognized elements and attributes, both in the MathML namespace and in other namespaces.
Because MathML is extensible, conformant "application/mathml-presentation+xml" processors must expect that content received is well-formed XML, but it cannot be guaranteed that the content is valid to a particular DTD or Schema or that the processor will recognize all of the elements and attributes in the document.
MathML instances do not contain version numbers, so processors and producers must follow the normative backward compatibility behavior described in this specification.
In computational contexts, the result of evaluating a MathML expression is system-specific, and is not guaranteed to be interoperable between systems.
This specification does not record a file extension for the media type "application/mathml-presentation+xml" because we expect tools processing files with MathML inside to have sufficient information with the generic media-type (application/mathml+xml) while other content negotiation forms will take advantage of specific media-types.
MathML Presentation
public.mathml.presentation
conforming to
public.mathml
(described above) conforming to public.xml
This registration has been submitted to community review and has been approved by IESG for registration with IANA.
application
mathml-content+xml
charset
parameter of
application/xml as specified in [RFC3023]As with other XML types and as noted in [RFC3023] section 10, repeated expansion of maliciously constructed XML entities can be used to consume large amounts of memory, which may cause XML processors in constrained environments to fail.
Several MathML elements may cause arbitrary URIs to be referenced. In this case, the security issues of [RFC3986], section 7, should be considered.
In common with HTML, MathML documents may reference external media such as images, style sheets, and scripting languages. Scripting languages are executable content. In this case, the security considerations in the Media Type registrations for those formats shall apply. Similarly, MathML annotation elements may contain content intended for execution or processing. In the case where the processor recognizes and processes the additional content, or where further processing of that content is dispatched to other processors, additional security issues potentially arise. Since the normative semantics of this specification do not require processing of annotation elements, such issues fall outside the domain of this registration document.
MathML may be used to describe mathematical expressions intended for evaluation in computing systems. Because of the nature of mathematics, a seemingly innocuous expression may lead to a computation which does not terminate or is impractically large. This introduces the risk that computational processors in constrained environments may fail.
In addition, because of the extensibility features for MathML and of XML in general, it is possible that "application/mathml-content+xml" may describe content that has security implications beyond those described here. However, if the processor follows only the normative semantics of this specification, this content will be outside the MathML namespace and shall be ignored.
This specification describes processing semantics that dictate behavior that must be followed when dealing with, among other things, unrecognized elements and attributes, both in the MathML namespace and in other namespaces.
Because MathML is extensible, conformant "application/mathml-content+xml" processors must expect that content received is well-formed XML, but it cannot be guaranteed that the content is valid to a particular DTD or Schema or that the processor will recognize all of the elements and attributes in the document.
MathML instances do not contain version numbers, so processors and producers must follow the normative backward compatibility behavior described in this specification.
In computational contexts, the result of evaluating a MathML expression is system-specific, and is not guaranteed to be interoperable between systems.
This specification does not record a file extension for the media type "application/mathml-content+xml" because we expect tools processing files with MathML inside to have sufficient information with the generic media-type (application/mathml+xml) while other content negotiation forms will take advantage of specific media-types.
MathML Content
public.mathml.content
conforming to
public.mathml
(described above) conforming to public.xml