Bug 564779 - Invalid FPI (Formal Public Identifier) regex in validator
Summary: Invalid FPI (Formal Public Identifier) regex in validator
Status: NEW
Alias: None
Product: WTP Source Editing
Classification: WebTools
Component: wst.xml (show other bugs)
Version: 3.18 (2020-06)   Edit
Hardware: PC Linux
: P3 major (vote)
Target Milestone: ---   Edit
Assignee: wst.xml CLA
QA Contact: Nitin Dahyabhai CLA
URL:
Whiteboard:
Keywords: needinfo
Depends on:
Blocks:
 
Reported: 2020-06-30 06:19 EDT by Tomisław Kityński CLA
Modified: 2020-06-30 19:26 EDT (History)
1 user (show)

See Also:


Attachments
Demonstration of flawed publicId regexp and its result during validation (130.93 KB, image/png)
2020-06-30 06:19 EDT, Tomisław Kityński CLA
no flags Details
XML file demonstrating improper behavior (as seen on included screenshot) (1.13 KB, application/xml)
2020-06-30 19:23 EDT, Tomisław Kityński CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tomisław Kityński CLA 2020-06-30 06:19:20 EDT
Created attachment 283443 [details]
Demonstration of flawed publicId regexp and its result during validation

Apparently regexp used in validating FPI (Formal Public Identifier, publicId attribute in public element of XML catalog) disallows spaces as a part of FPI, but according to http://xml.coverpages.org/tauber-fpi.html, `owner name component` allows spaces. In fact well know (yet not registered) FPI-s do contain spaces, e.g: `-//W3C//DTD HTML 4.01//EN` or `-//OASIS//DTD DocBook XML V4.1.2//EN` or even registered ones, like `+//IDN python.org//DTD XML Bookmark Exchange Language 1.0//EN//XML` (see https://www.ietf.org/rfc/rfc3151.txt).

In attached screenshot there is full regex in tooltip displayed, so you can check the space is missing and thus valid publicIds are marked as invalid.
Comment 1 Nitin Dahyabhai CLA 2020-06-30 08:55:32 EDT
Can you attach an xml file that can be used to reproduce the problem?
Comment 2 Tomisław Kityński CLA 2020-06-30 19:23:47 EDT
Created attachment 283456 [details]
XML file demonstrating improper behavior (as seen on included screenshot)

Here it goes.