Bug 1007847
| Summary: | sgdisk -i segfaults when parameter is too large | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Richard W.M. Jones <rjones> | ||||
| Component: | gdisk | Assignee: | Terje Røsten <terje.rosten> | ||||
| Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
| Severity: | medium | Docs Contact: | |||||
| Priority: | medium | ||||||
| Version: | rawhide | CC: | bfan, leiwang, orion, wshi | ||||
| Target Milestone: | --- | ||||||
| Target Release: | --- | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | gdisk-0.8.7-2.fc18 | Doc Type: | Bug Fix | ||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | 1007761 | Environment: | |||||
| Last Closed: | 2013-09-23 00:30:34 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Bug Depends On: | |||||||
| Bug Blocks: | 1007761 | ||||||
| Attachments: |
|
||||||
|
Description
Richard W.M. Jones
2013-09-13 12:59:35 UTC
Also fails on Fedora Rawhide.
The issue is that partNum is passed direct from the command
line (actually partNum == 1185-1 here) and is not bounds-checked
at all, so:
(gdb) frame 1
#1 0x000000000041015e in GPTData::ShowPartDetails (
this=this@entry=0x7fffffffc470, partNum=<optimized out>) at gpt.cc:1406
1406 partitions[partNum].ShowDetails(blockSize);
fails in the array index.
Created attachment 797335 [details]
gdisk-0.8.7-add-range-check.patch
I pushed this patch to Rawhide. Will send it upstream shortly.
Was not meant to be private. Thanks for report and patch! gdisk-0.8.7-2.fc19 has been submitted as an update for Fedora 19. https://admin.fedoraproject.org/updates/gdisk-0.8.7-2.fc19 gdisk-0.8.7-2.fc20 has been submitted as an update for Fedora 20. https://admin.fedoraproject.org/updates/gdisk-0.8.7-2.fc20 gdisk-0.8.7-2.fc18 has been submitted as an update for Fedora 18. https://admin.fedoraproject.org/updates/gdisk-0.8.7-2.fc18 Package gdisk-0.8.7-2.fc20: * should fix your issue, * was pushed to the Fedora 20 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing gdisk-0.8.7-2.fc20' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2013-16778/gdisk-0.8.7-2.fc20 then log in and leave karma (feedback). gdisk-0.8.7-2.fc20 has been pushed to the Fedora 20 stable repository. If problems still persist, please make note of it in this bug report. gdisk-0.8.7-2.fc19 has been pushed to the Fedora 19 stable repository. If problems still persist, please make note of it in this bug report. gdisk-0.8.7-2.fc18 has been pushed to the Fedora 18 stable repository. If problems still persist, please make note of it in this bug report. |