Skip to content

fix: the wav file playback driver copies chunk data ... in...#288

Open
orbisai0security wants to merge 1 commit intoFOSDEM:masterfrom
orbisai0security:fix-v-004-wav-header-buffer-overflow
Open

fix: the wav file playback driver copies chunk data ... in...#288
orbisai0security wants to merge 1 commit intoFOSDEM:masterfrom
orbisai0security:fix-v-004-wav-header-buffer-overflow

Conversation

@orbisai0security
Copy link
Copy Markdown

Summary

Fix high severity security issue in hardware/firmware/audio_board/vendor/Audio/play_sd_wav.cpp.

Vulnerability

Field Value
ID V-004
Severity HIGH
Scanner multi_agent_ai
Rule V-004
File hardware/firmware/audio_board/vendor/Audio/play_sd_wav.cpp:254

Description: The WAV file playback driver copies chunk data into a fixed-size header buffer using an offset and length derived directly from the WAV file's chunk headers, without validating that header_offset + len stays within the buffer boundary. A maliciously crafted WAV file placed on the SD card can specify a chunk length that causes the memcpy to write beyond the header buffer, corrupting adjacent memory on the audio microcontroller. This affects any device that plays WAV files from an SD card.

Changes

  • hardware/firmware/audio_board/vendor/Audio/play_sd_wav.cpp

Verification

  • Build passes
  • Scanner re-scan confirms fix
  • LLM code review passed

Automated security fix by OrbisAI Security

Automated security fix generated by Orbis Security AI
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant