ome / omero-web

Django-based OMERO.web client
https://www.openmicroscopy.org/omero
17 stars 31 forks source link

linkify supports urls that include {}[] characters #595

Open sukunis opened 1 week ago

sukunis commented 1 week ago

Test by adding URL: https://openbis-eln-lims.ethz.ch/openbis/webapp/eln-lims/?menuUniqueId={%22type%22:%22SAMPLE%22,%22id%22:%2220150127162826183-170%22}&viewName=showViewSamplePageFromPermId&viewData=%2220150127162826183-170%22

grafik

knabar commented 1 week ago

According to https://www.ietf.org/rfc/rfc3986.txt, square brackets are only allowed for the host part (to deal with IPv4/v6 addresses) and must be encoded otherwise. Curly brackets are considered unsafe and should be encoded.

Obviously these rules are not followed in common usage, but we should be sure not to introduce any potential issues by automatically linkifying those URIs.