bug-cpio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-cpio] cpio large filesize buffer overflow


From: Dmitry V. Levin
Subject: Re: [Bug-cpio] cpio large filesize buffer overflow
Date: Wed, 16 Nov 2005 03:08:06 +0300

Hi,

On Sat, 12 Nov 2005 16:36:56 EET, Sergey Poznyakoff wrote:
> Thank you. Fixed.

This fix introduces easily reproducable bug (probably typo):
@@ -547,4 +701,4 @@ process_copy_out ()
                      file_hdr.c_tar_linkname = otherfile;
-                     write_out_header (&file_hdr, out_file_des);
-                     break;
+                     if (write_out_header (&file_hdr, out_file_des))
+                       continue;
                    }

Just try following test:
mkdir dir && touch dir/a && ln dir/a dir/b &&
        find dir |cpio --create --quiet --format=tar |tar tf -


-- 
ldv

Attachment: pgpZNIvjK1yHA.pgp
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]