Describe the bug
Type assertion at fetcher/fetcher.go:883 on p.Header without ok check. Malformed MIME headers cause panic.
To reproduce
- Receive email with malformed MIME structure
- Type assertion fails
- Application panics
Expected behavior
Use type assertion with ok check: h, ok := p.Header.(*mail.InlineHeader)
Matcha version
master
OS
All
Additional context
File: fetcher/fetcher.go line 883
Panic on unexpected header type
Describe the bug
Type assertion at fetcher/fetcher.go:883 on p.Header without ok check. Malformed MIME headers cause panic.
To reproduce
Expected behavior
Use type assertion with ok check: h, ok := p.Header.(*mail.InlineHeader)
Matcha version
master
OS
All
Additional context
File: fetcher/fetcher.go line 883
Panic on unexpected header type