Project

General

Profile

feature request #9114

Handle malformed URIs in user type

Added by Andreas Müller 10 months ago. Updated 24 days ago.

Status:
In Progress
Priority:
Priority14
Assignee:
Category:
cdmlib
Target version:
Start date:
06/30/2020
Due date:
% Done:

40%

Severity:
normal
Tags:

Description

The fix for #9111 should be moved to a new URI user type wrapper that is used instead of the current URI class. Otherwise the workaround needs to be applied whereever URIs are used.


Related issues

Related to Edit - feature request #9111: Handle Malformed URIs Resolved 06/30/2020

Associated revisions

Revision 26790e9b (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt URI to wrapper in cdmlib-app

Revision de8249cf (diff)
Added by Andreas Müller 3 months ago

ref #9114 add URI Wrapper and replace all java.net.URI occurrences by the wrapper in cdmlib

Revision 999006a7 (diff)
Added by Andreas Müller 3 months ago

ref #9114 preliminary ignore RdfViewTest

Revision 4cd4de2d (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt URIs to URI wrapper in vaadin

Revision dd94c99b (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt URI to wrapper in cdmlib-app (cont.)

Revision bf3cb991 (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt some classes with URI to wrapper in taxeditor

Revision 96378f2b (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt some classes with URI to wrapper in taxeditor (cont.)

Revision 5b2e9e6b (diff)
Added by Andreas Müller 3 months ago

ref #9114 add compareTo to URI wrapper

Revision f5a55599 (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt some classes with URI to wrapper in taxeditor (cont.)

Revision 5dfe9f9b (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt some classes with URI to wrapper in taxeditor (cont.)

Revision 15c5de38 (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt some classes with URI to wrapper in taxeditor (cont.)

Revision 7b06bd8f (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt some classes with URI to wrapper in taxeditor (cont.)

Revision 5acb8103 (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt some classes with URI to wrapper in taxeditor (cont.)

Revision 4d87641f (diff)
Added by Andreas Müller 3 months ago

ref #9114 add toFile() to URI to wrapper

Revision 6b33224a (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt javadoc for new URI wrapper user type

Revision f9c3f295 (diff)
Added by Andreas Müller 3 months ago

ref #9114 adapt json mapping to new URI wrapper

Revision 3154d43f (diff)
Added by Andreas Müller 3 months ago

ref #9114 further adapt some classes to URI wrapper in taxeditor

Revision 4ad992ed (diff)
Added by Andreas Müller 3 months ago

ref #9114 further adapt jsonConfigurations and add new constructor to URI wrapper

Revision c22065e1 (diff)
Added by Andreas Müller 3 months ago

ref #9114 fix RdfViewTest

Revision 9916da4a (diff)
Added by Andreas Müller 3 months ago

ref #9111, ref #9114 remove TaxEditor specific URI encoding code as encoding is handled in cdmlib now

Revision ac58825c (diff)
Added by Andreas Müller 2 months ago

ref #9114 fix dozer mapping by reverting URI mappings to java.net.URI

History

#1 Updated by Andreas Müller 10 months ago

#2 Updated by Andreas Müller 3 months ago

  • Description updated (diff)
  • % Done changed from 0 to 40

#3 Updated by Andreas Müller 3 months ago

  • Status changed from New to In Progress

I implemented a new class eu.etaxonomy.cdm.common.URI and use this in model but also at other places like import sources.

Unfortunately, simply subclassing java.net.URI was not possible as it is final.

A method getJavaUri() exists to transform the above class to standard java.net.URI.

Currently there are still 2 open issues:

  • httpinvoker: within httpinvoker there is still a ClassCastException and therefore TaxEditor fails to build. First I thought this is because CdmModelCache needs to be build anew, but running the script does not change the model cache file so this does not seem to be the reason
  • RdfViewTest.testMarshalRdf does not run successfully and therefore I set it to ignore. The children type dc:identifier/ do not seem to be build correctly.

#4 Updated by Andreas Müller 3 months ago

  • Assignee changed from Andreas Müller to Katja Luther
  • Target version changed from Release 5.18 to Release 5.19

Katja, can you please check if you can find out what the httpinvoker problem is. I currently can't start the TaxEditor from the IDE for debugging.

#5 Updated by Andreas Müller 3 months ago

In #9111#note-1 AK suggests to also encode fragment and query parts. This has not been implemented in the original code in #9111 which has been copied to cdmlib.

I think we should also implement it for fragment and query. Probably not for authority and scheme?

Also the handling of backslash needs to be discussed. In the original version backslash was encoded, too. This is probably not wanted, at least not for the path part. Currently a URISyntaxException is thrown if path contains a backslash.

#6 Updated by Andreas Müller 2 months ago

  • Target version changed from Release 5.19 to Release 5.21

#7 Updated by Katja Luther about 1 month ago

  • Target version changed from Release 5.21 to Release 5.22

#8 Updated by Andreas Müller 24 days ago

  • Tags set to fast

This ticket seems to be done or needs to be splitted into an open issues ticket. It can be moved back to 5.19(?) afterwards.

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 40 MB)