economidis-nick / createXSDforxMCF

2 stars 2 forks source link

Example files to be revised wrt. xsi:noNamespaceSchemaLocation. #82

Open DrCaFr opened 1 year ago

DrCaFr commented 1 year ago

Do we still need attribute xsi:noNamespaceSchemaLocation="xmcf_3_1_1.xsd" in <xmcf/> element?

Compare this with STEP AP242 XML. @maxungerer may support with more detailed information.

maxungerer commented 1 year ago

I recently learned that schema locations with URLs should not be included in an XSD header due to the risk of man-in-the-middle attacks. For further readings see chapter "Remote Schema Poisoning" in https://cheatsheetseries.owasp.org/cheatsheets/XML_Security_Cheat_Sheet.html

economidis-nick commented 1 year ago

I think we had discussed this at some point but did not move this way.

As far as I can remember, we chose the noNamespaceSchemaLocation for 2 reasons:

If I am not mistaken, we are consistent with FATXML.

I do not object to revising it though. What would you propose that we use instead of the xsi:noNamespaceSchemaLocation="xmcf_3_1_1.xsd" ? Could you provide a link to the STEP schema and point me to the relevant line, please ?

DrCaFr commented 1 year ago

I am not sure, how noNamespaceSchemaLocation my allow for a man-in-the-middle attack. We really need to consider that confusions may occur :wink: …