{"id":947,"date":"2016-11-22T18:49:11","date_gmt":"2016-11-22T16:49:11","guid":{"rendered":"http:\/\/blogs.gentoo.org\/ago\/?p=947"},"modified":"2016-11-22T18:49:11","modified_gmt":"2016-11-22T16:49:11","slug":"metapixel-multiple-assertion-failures","status":"publish","type":"post","link":"https:\/\/blogs.gentoo.org\/ago\/2016\/11\/22\/metapixel-multiple-assertion-failures\/","title":{"rendered":"metapixel: multiple assertion failures"},"content":{"rendered":"<p><strong>Description<\/strong>:<br \/>\n<a href=\"http:\/\/www.complang.tuwien.ac.at\/schani\/metapixel\/\">metapixel<\/a> is a program for generating photomosaics.<\/p>\n<p>A fuzzing on metapixel-imagesize revealed multiple assertion failures. The latest upstream release was about ten years ago, so I didn&#8217;t made any report. The bugs do not reside in any shared object which aren&#8217;t provided by the package. If you have a web application which relies on the metapixel-imagesize binary, then you are affected. Since the crashes reside in the command line tool, they may don&#8217;t warrant a CVE at all, but some distros and packagers would have the bugs fixed in their repository, so I&#8217;m sharing them.<\/p>\n<p><strong>Affected version<\/strong>:<br \/>\n1.0.2<br \/>\n<strong>Output\/failure<\/strong>:<br \/>\nmetapixel-imagesize: rwgif.c:59: void *open_gif_file(const char *, int *, int *): Assertion `data-&gt;file !=0&#8242; failed.<br \/>\n<strong>Commit fix<\/strong>:<br \/>\nN\/A<br \/>\n<strong>Fixed version<\/strong>:<br \/>\nN\/A<br \/>\n<strong>Testcase<\/strong>:<br \/>\n<a href=\"https:\/\/github.com\/asarubbo\/poc\/blob\/master\/00059-metapixel-assert-open_gif_file-1\">https:\/\/github.com\/asarubbo\/poc\/blob\/master\/00059-metapixel-assert-open_gif_file-1<\/a><\/p>\n<p>##########################################<\/p>\n<p><strong>Affected version<\/strong>:<br \/>\n1.0.2<br \/>\n<strong>Output\/failure<\/strong>:<br \/>\nmetapixel-imagesize: rwgif.c:63: void *open_gif_file(const char *, int *, int *): Assertion `DGifGetRecordType(data-&gt;file, &amp;record_type) != 0&#8242; failed.<br \/>\n<strong>Commit fix<\/strong>:<br \/>\nN\/A<br \/>\n<strong>Fixed version<\/strong>:<br \/>\nN\/A<br \/>\n<strong>Testcase<\/strong>:<br \/>\n<a href=\"https:\/\/github.com\/asarubbo\/poc\/blob\/master\/00060-metapixel-assert-open_gif_file-2\">https:\/\/github.com\/asarubbo\/poc\/blob\/master\/00060-metapixel-assert-open_gif_file-2<\/a><\/p>\n<p>##########################################<\/p>\n<p><strong>Affected version<\/strong>:<br \/>\n1.0.2<br \/>\n<strong>Output\/failure<\/strong>:<br \/>\nmetapixel-imagesize: rwgif.c:68: void *open_gif_file(const char *, int *, int *): Assertion `DGifGetImageDesc(data-&gt;file) != 0&#8242; failed.<br \/>\n<strong>Commit fix<\/strong>:<br \/>\nN\/A<br \/>\n<strong>Fixed version<\/strong>:<br \/>\nN\/A<br \/>\n<strong>Testcase<\/strong>:<br \/>\n<a href=\"https:\/\/github.com\/asarubbo\/poc\/blob\/master\/00061-metapixel-assert-open_gif_file-3\">https:\/\/github.com\/asarubbo\/poc\/blob\/master\/00061-metapixel-assert-open_gif_file-3<\/a><\/p>\n<p>##########################################<\/p>\n<p><strong>Affected version<\/strong>:<br \/>\n1.0.2<br \/>\n<strong>Output\/failure<\/strong>:<br \/>\nmetapixel-imagesize: rwgif.c:102: void *open_gif_file(const char *, int *, int *): Assertion `DGifGetExtension(data-&gt;file, &amp;ext_code, &amp;ext) != 0&#8242; failed.<br \/>\n<strong>Commit fix<\/strong>:<br \/>\nN\/A<br \/>\n<strong>Fixed version<\/strong>:<br \/>\nN\/A<br \/>\n<strong>Testcase<\/strong>:<br \/>\n<a href=\"https:\/\/github.com\/asarubbo\/poc\/blob\/master\/00062-metapixel-assert-open_gif_file-4\">https:\/\/github.com\/asarubbo\/poc\/blob\/master\/00062-metapixel-assert-open_gif_file-4<\/a><\/p>\n<p>##########################################<\/p>\n<p><strong>Affected version<\/strong>:<br \/>\n1.0.2<br \/>\n<strong>Output\/failure<\/strong>:<br \/>\nmetapixel-imagesize: rwgif.c:106: void *open_gif_file(const char *, int *, int *): Assertion `DGifGetExtensionNext(data-&gt;file, &amp;ext) != 0&#8242; failed.<br \/>\n<strong>Commit fix<\/strong>:<br \/>\nN\/A<br \/>\n<strong>Fixed version<\/strong>:<br \/>\nN\/A<br \/>\n<strong>Testcase<\/strong>:<br \/>\n<a href=\"https:\/\/github.com\/asarubbo\/poc\/blob\/master\/00063-metapixel-assert-open_gif_file-5\">https:\/\/github.com\/asarubbo\/poc\/blob\/master\/00063-metapixel-assert-open_gif_file-5<\/a><\/p>\n<p><strong>Credit:<\/strong><br \/>\nThese bugs were discovered by Agostino Sarubbo of Gentoo.<\/p>\n<p><strong>Timeline:<\/strong><br \/>\n2016-11-22: bugs discovered<br \/>\n2016-11-22: blog post about the issues<\/p>\n<p><strong>Note:<\/strong><br \/>\nThese bugs were found with <a href=\"http:\/\/lcamtuf.coredump.cx\/afl\">American Fuzzy Lop<\/a>.<\/p>\n<p><strong>Permalink:<\/strong><\/p>\n<blockquote data-secret=\"eWO6IG1dXb\" class=\"wp-embedded-content\"><p><a href=\"http:\/\/blogs.gentoo.org\/ago\/2016\/11\/22\/metapixel-multiple-assertion-failures\/\">metapixel: multiple assertion failures<\/a><\/p><\/blockquote>\n<p><iframe class=\"wp-embedded-content\" sandbox=\"allow-scripts\" security=\"restricted\" style=\"position: absolute; clip: rect(1px, 1px, 1px, 1px);\" src=\"http:\/\/blogs.gentoo.org\/ago\/2016\/11\/22\/metapixel-multiple-assertion-failures\/embed\/#?secret=eWO6IG1dXb\" data-secret=\"eWO6IG1dXb\" width=\"600\" height=\"338\" title=\"&#8220;metapixel: multiple assertion failures&#8221; &#8212; agostino&#039;s blog\" frameborder=\"0\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\"><\/iframe><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Description: metapixel is a program for generating photomosaics. A fuzzing on metapixel-imagesize revealed multiple assertion failures. The latest upstream release was about ten years ago, so I didn&#8217;t made any report. The bugs do not reside in any shared object &hellip; <a href=\"https:\/\/blogs.gentoo.org\/ago\/2016\/11\/22\/metapixel-multiple-assertion-failures\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":140,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"spay_email":"","jetpack_publicize_message":"","jetpack_is_tweetstorm":false,"jetpack_publicize_feature_enabled":true},"categories":[12,10],"tags":[],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p2EaBc-fh","_links":{"self":[{"href":"https:\/\/blogs.gentoo.org\/ago\/wp-json\/wp\/v2\/posts\/947"}],"collection":[{"href":"https:\/\/blogs.gentoo.org\/ago\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.gentoo.org\/ago\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.gentoo.org\/ago\/wp-json\/wp\/v2\/users\/140"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.gentoo.org\/ago\/wp-json\/wp\/v2\/comments?post=947"}],"version-history":[{"count":6,"href":"https:\/\/blogs.gentoo.org\/ago\/wp-json\/wp\/v2\/posts\/947\/revisions"}],"predecessor-version":[{"id":957,"href":"https:\/\/blogs.gentoo.org\/ago\/wp-json\/wp\/v2\/posts\/947\/revisions\/957"}],"wp:attachment":[{"href":"https:\/\/blogs.gentoo.org\/ago\/wp-json\/wp\/v2\/media?parent=947"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.gentoo.org\/ago\/wp-json\/wp\/v2\/categories?post=947"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.gentoo.org\/ago\/wp-json\/wp\/v2\/tags?post=947"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}