[FFmpeg-trac] #8466(avformat:reopened): av_url_split violates RFC2396, fails to parse URLs

FFmpeg trac at avcodec.org
Sun Feb 16 01:23:22 EET 2020


#8466: av_url_split violates RFC2396, fails to parse URLs
-------------------------------------+------------------------------------
             Reporter:  aitte        |                    Owner:
                 Type:  defect       |                   Status:  reopened
             Priority:  normal       |                Component:  avformat
              Version:  unspecified  |               Resolution:
             Keywords:  http         |               Blocked By:
             Blocking:               |  Reproduced by developer:  0
Analyzed by developer:  0            |
-------------------------------------+------------------------------------
Changes (by aitte):

 * status:  closed => reopened
 * resolution:  fixed =>


Comment:

 Oh and it was great to see that you even made a sanitizer for the
 connection algorithm ("http_open_cnx_internal") which auto-adds a slash if
 there was no slash in the input URL given to the function.

 I'm actually re-opening this to ask a question, though, for other
 reviewers to consider:

 https://git.videolan.org/?p=ffmpeg.git;a=commitdiff;h=a3d8875df1f71e62a36c583cee638ab1d51a71d3

 Note how the code is adding a "/" slash if the first character of the path
 is a question mark. Is there any problem if the URL is
 "https://example.com#foo"?

 It looks to me like the hashmark check a few lines earlier (
 https://git.videolan.org/?p=ffmpeg.git;a=commitdiff;h=987ce96d41d21a120e6109f9bb1e3a9dcddbf30b
 ) puts a null byte at the hashmark position to "erase the hashmark and
 everything after it" already, so I guess there is no problem! Just asking
 to be sure. :-)

--
Ticket URL: <https://trac.ffmpeg.org/ticket/8466#comment:7>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list