[vlc-commits] webvtt: Fix potential OOB read

Hugo Beauzée-Luyssen git at videolan.org
Thu May 23 17:21:01 CEST 2019


vlc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Tue Mar  5 15:11:22 2019 +0100| [ca3eb137460db80cf50c145242606157cde50a96] | committer: Hugo Beauzée-Luyssen

webvtt: Fix potential OOB read

https://hackerone.com/reports/503663

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=ca3eb137460db80cf50c145242606157cde50a96
---

 modules/codec/webvtt/webvtt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/codec/webvtt/webvtt.c b/modules/codec/webvtt/webvtt.c
index 76b8c0a6c4..02513f2fb8 100644
--- a/modules/codec/webvtt/webvtt.c
+++ b/modules/codec/webvtt/webvtt.c
@@ -247,7 +247,7 @@ void webvtt_text_parser_Feed( webvtt_text_parser_t *p, char *psz_line )
             if( webvtt_scan_time( p->reads[1], &i_start ) &&
                 webvtt_scan_time( psz_split + 5,  &i_stop ) && i_start <= i_stop )
             {
-                const char *psz_attrs = strchr( psz_split + 5 + 9, ' ' );
+                const char *psz_attrs = strchr( psz_split + 5 + 5, ' ' );
                 p->p_cue = ( p->pf_get_cue ) ? p->pf_get_cue( p->priv ) : NULL;
                 if( p->p_cue )
                 {



More information about the vlc-commits mailing list