Crash : Malformed .bmp files lead to crash. #71960
Labels
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
10 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender#71960
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
There is no bounds checking in
source\blender\imbuf\intern\bmp.c
leading to out of bound access if the bmp file is malformed.repro:
c:\Users\[username]\Documents\
Note: The problem exists in the 16bpp (rgb565) codepath as well but i had nothing that could write that format.
Note2: The header checks also do not respect the buffer bounds, i didn't have time to make to make a crashing bmp, but whoever will work on this will have to fix that as well.
note3: the crashy bmp files are created by taking a regular bmp file and truncating it to about half their size, leading to a correct header, but not enough image data in the file.
[Original report]
System Information
Operating system: Windows 10 Pro, Version 1903, Build: 18362.476
Graphics card: Nvidia GTX 980 TI Driver 441.20
Blender Version
Broken: 2.181 release
Worked: (optional)
On fresh install of 2.81, startup with default project.
Select the Shader tab and Blender crashes with:
found bundled python: C:\Program Files\Blender Foundation\Blender 2.81\2.81\python
Error : EXCEPTION_ACCESS_VIOLATION
Address : 0x00007FF63621A4B0
Module : C:\Program Files\Blender Foundation\Blender 2.81\blender.exe
Added subscriber: @Ed-H
#83324 was marked as duplicate of this issue
#68164 was marked as duplicate of this issue
blender_debug_output.txt
blender_system_info.txt
Had the same issue with 2.80
Added subscriber: @mano-wii
This is strange, it seems that the graphics driver is one of the latest.
https://www.geforce.com/drivers?nvid=nv-int-bnnr-96776#cid=internal_en-us_banner_gtx_900_series_upgrade
But we do not have much information to know what is happening.
Try after loading Factory Settings. (
File -> Defaults -> Load Factory Settings
)Did loading the factory settings have any effect?
No
Added subscriber: @iss
Changed status from 'Needs Developer To Reproduce' to: 'Needs User Info'
Is this still an issue with latest build? https://builder.blender.org/download/
Added subscribers: @ronsn, @robbott
Still fails with 2.82:
Build info:
Also tested with 2.83:
Still fails.
Build info:
Changed status from 'Needs User Info' to: 'Needs Developer To Reproduce'
Still happening with 'blender-2.83-cdfaddbb1d42-windows64'blender_system_info.txt
blender_debug_output.txt
Is there anything else I can do on my end?
This comment was removed by @Ed-H
Just tested with 2.90 May 18th alpha. Still crashes on Shader tab.
Added subscriber: @Delenn97
Was a fix ever found for this? Or can I nolonger use blender
I noticed that if I open this project and click the Shader tab Blender does not crash. So maybe there is some initialization or un-initialized value somewhere(?).
Detailing-Project-File.zip
Added subscriber: @LazyDodo
Can you try a daily 2.90? When it crashes it should with a bit of luck write out a crash report that may help tracking this down.
Still crashed at 2.90 6/1/2020 build. Here are the debug / info files.
Running NVIDIA drivers 446.14 on 980 TI.
blender_system_info.txt
blender_debug_output.txt
blender.crash.txt
Also tried "factory startup" cmd still no luck.
Seems to crash while trying to generate a thumbnail for a
.bmp
file, is there any chance you could run ProcessMonitor and see what the last.bmp
file was that blender read? and then do 2 two things.Changed status from 'Needs Developer To Reproduce' to: 'Needs User Info'
Changed status from 'Needs User Info' to: 'Confirmed'
Actually i made some bad .bmp files and can repro easily, there is NO bounds checking whatsoever in the bmp loader.
c:\Users\[username]\Documents\
Note: The problem exists in the 16bpp (rgb565) codepath as well but i had nothing that could write that format.
Note2: The header checks also do not respect the buffer bounds, i didn't have time to make to make a crashing bmp, but whoever will work on this will have to fix that as well.
note3: the crashy bmp files are created by taking a regular bmp file and truncating it to about half their size, leading to a correct header, but not enough image data in the file.
That fixed it.
The file was called "hokie.bmp" and it was not a valid .BMP file. Must have been corrupted. I cannot open it with any other graphics. tool. This file was in the "My Documents" folder; which it looks like Blender goes through and reads all the media there. I probably could change that directory in the upper left frame to point to a more specific place for Blender related media. I have attached problem file here.
Thank you for your analysis.
Not sure if you want it, but i repaired the file by just padding it with white pixels
Error : EXCEPTION_ACCESS_VIOLATION when selecting the Shader tab on new projectto Crash : Malformed .bmp files lead to crash.I was actually able to open it with microsoft Code(??!) I had to open a valid BMP file first though.
This was probably created by a pinball table editor. I've deleted it, thanks.
Images & Movies isn't a project really, so I guess I will add #vfx_video
Or we can update query https://developer.blender.org/maniphest/query/J_RaaSzk5wr0/
Added subscribers: @Kealinit, @rjg
Just wanted to point out that, the original cause of the Shader Editor crash is because Blender would scan the "My Documents" folder for image files when the user selected the Shader tab; and in my case hit a bad .BMP file in the process.
Added subscriber: @Sergey
We should at least add a pixel data size check in the the bmp implementation.
This issue was referenced by
7c864388fc
Changed status from 'Confirmed' to: 'Resolved'
This issue was referenced by
5b08cbae51