mirror of
				https://github.com/devine-dl/pywidevine.git
				synced 2025-11-04 11:54:50 +00:00 
			
		
		
		
	PSSH: Fix get_as_box parsing on arbitrary init data
An IOError can occur if the mp4 box parsing fails because it could not read enough bytes.
This commit is contained in:
		
							parent
							
								
									6a286a4c23
								
							
						
					
					
						commit
						97126391c4
					
				@ -112,7 +112,7 @@ class PSSH:
 | 
			
		||||
        if isinstance(data, bytes):
 | 
			
		||||
            try:
 | 
			
		||||
                data = Box.parse(data)
 | 
			
		||||
            except construct.ConstructError:
 | 
			
		||||
            except (IOError, construct.ConstructError):
 | 
			
		||||
                if strict:
 | 
			
		||||
                    try:
 | 
			
		||||
                        cenc_header = WidevinePsshData()
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user