In coders/ps.c in ImageMagick 7.0.7-0 Q16, a DoS in ReadPSImage() due to lack of an EOF (End of File) check might cause huge CPU consumption. When a crafted PSD file, which claims a large "extent" field in the header but does not contain sufficient backing data, is provided, the loop over "length" would consume huge CPU resources, since there is no EOF check inside the loop.
[
{
"signature_version": "v1",
"deprecated": false,
"source": "https://github.com/imagemagick/imagemagick/commit/bdbbb13f1fe9b7e2465502c500561720f7456aac",
"target": {
"function": "ReadPSImage",
"file": "coders/ps.c"
},
"digest": {
"function_hash": "9537011764912027405671843399843009265",
"length": 14625.0
},
"signature_type": "Function",
"id": "CVE-2017-14172-630eb8f5"
},
{
"signature_version": "v1",
"deprecated": false,
"source": "https://github.com/imagemagick/imagemagick/commit/bdbbb13f1fe9b7e2465502c500561720f7456aac",
"target": {
"function": "RegisterPSImage",
"file": "coders/ps.c"
},
"digest": {
"function_hash": "58479823145618228581022058710780723602",
"length": 1798.0
},
"signature_type": "Function",
"id": "CVE-2017-14172-9ee869ac"
},
{
"signature_version": "v1",
"deprecated": false,
"source": "https://github.com/imagemagick/imagemagick/commit/bdbbb13f1fe9b7e2465502c500561720f7456aac",
"target": {
"file": "coders/ps.c"
},
"digest": {
"line_hashes": [
"135292126018698160666468971952564640438",
"132534222829792808370145742001388724863",
"41418898004768674788462144192458876253",
"197431814783228836736986560833224504274",
"185876525368505560160034891656701599451",
"161655646774896142655207482874066622902",
"70495320583446461142367828567072874858",
"68764566489383548091647861790507884341",
"214840200551557280338300049035010879053",
"214180508259772947281718000033543135117",
"271993194180293791857269753845963465192",
"260084162069260263156073204012954071279",
"28253425513397365356152378281095875034",
"188467617281027800144393604961558690760",
"312485988164934789024420650912925934829",
"204267151015325515462831817699181972122",
"328035841436348926912287969429653237274",
"177106032570526478991809101685416653651",
"312485988164934789024420650912925934829",
"204267151015325515462831817699181972122",
"328035841436348926912287969429653237274",
"226453130297119401775123572952653347687",
"312485988164934789024420650912925934829",
"204267151015325515462831817699181972122",
"328035841436348926912287969429653237274",
"188467617281027800144393604961558690760",
"312485988164934789024420650912925934829",
"204267151015325515462831817699181972122",
"328035841436348926912287969429653237274",
"274675445605238745842961799433009229231",
"150075779093929840955088750206106956602",
"222431508817935265264542158134725646143",
"75115875504680177083009774367114069424"
],
"threshold": 0.9
},
"signature_type": "Line",
"id": "CVE-2017-14172-ba977e77"
}
]