[MacPorts] #14067: livecheck.distname is not properly escaped in livecheck.regex
#14067: livecheck.distname is not properly escaped in livecheck.regex -------------------------------------+-------------------------------------- Reporter: ryandesign@macports.org | Owner: macports-tickets@lists.macosforge.org Type: defect | Status: new Priority: Normal | Milestone: MacPorts base bugs Component: base | Version: 1.7.0 Keywords: | -------------------------------------+-------------------------------------- `livecheck.distname` is not being properly escaped before being put into `livecheck.regex`. I noticed this problem while trying to update the livecheck for osxvnc, setting `livecheck.distname Vine Server(OSXvnc)`. With `livecheck.check sourceforge`, this results in the regex "`<title>Vine Server(OSXvnc) (.*) released.*</title>`" which is incorrect. The regex I wanted was "`<title>Vine Server\(OSXvnc\) (.*) released.*</title>`". There must be a Tcl function we can use which would properly escape a string for use in a regular expression, like [http://www.php.net/preg_quote preg_quote()] in php. Looking through all ports, I see that fixing this will break the livecheck in the portfiles for fusefs and spotlightfs, which currently assume this bug exists. -- Ticket URL: <http://trac.macosforge.org/projects/macports/ticket/14067> MacPorts </projects/macports> Ports system for Mac OS
#14067: livecheck.distname is not properly escaped in livecheck.regex --------------------------------------+------------------------------------- Reporter: ryandesign@macports.org | Owner: macports-tickets@lists.macosforge.org Type: defect | Status: new Priority: Normal | Milestone: MacPorts base bugs Component: base | Version: 1.7.0 Resolution: | Keywords: --------------------------------------+------------------------------------- Comment (by afb@macports.org): Replying to [ticket:14067 ryandesign@macports.org]:
There must be a Tcl function we can use which would properly escape a string for use in a regular expression, like [http://www.php.net/preg_quote preg_quote()] in php.
Doesn't look that way, but then again it isn't impossible to just add one either. -- Ticket URL: <http://trac.macosforge.org/projects/macports/ticket/14067#comment:1> MacPorts </projects/macports> Ports system for Mac OS
#14067: livecheck.distname is not properly escaped in livecheck.regex --------------------------------------+------------------------------------- Reporter: ryandesign@macports.org | Owner: macports-tickets@lists.macosforge.org Type: defect | Status: new Priority: Normal | Milestone: MacPorts base bugs Component: base | Version: 1.7.0 Resolution: | Keywords: --------------------------------------+------------------------------------- Comment (by raimue@macports.org): Fixed in r34667. -- Ticket URL: <http://trac.macosforge.org/projects/macports/ticket/14067#comment:2> MacPorts </projects/macports> Ports system for Mac OS
#14067: livecheck.distname is not properly escaped in livecheck.regex --------------------------------------+------------------------------------- Reporter: ryandesign@macports.org | Owner: macports-tickets@lists.macosforge.org Type: defect | Status: closed Priority: Normal | Milestone: MacPorts base bugs Component: base | Version: 1.7.0 Resolution: fixed | Keywords: --------------------------------------+------------------------------------- Changes (by raimue@macports.org): * status: new => closed * resolution: => fixed -- Ticket URL: <http://trac.macosforge.org/projects/macports/ticket/14067#comment:3> MacPorts </projects/macports> Ports system for Mac OS
#14067: livecheck.distname is not properly escaped in livecheck.regex --------------------------------------+------------------------------------- Reporter: ryandesign@macports.org | Owner: macports-tickets@lists.macosforge.org Type: defect | Status: closed Priority: Normal | Milestone: MacPorts base bugs Component: base | Version: 1.7.0 Resolution: fixed | Keywords: --------------------------------------+------------------------------------- Comment (by raimue@macports.org): Now really fixed in r34693, the previous commit broke other regexes. -- Ticket URL: <http://trac.macosforge.org/projects/macports/ticket/14067#comment:4> MacPorts </projects/macports> Ports system for Mac OS
participants (1)
-
MacPorts