NetBSD-Bugs archive

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

Re: kern/48852 CD9660 RockRidge: device files not properly handled



The following reply was made to PR kern/48852; it has been noted by GNATS.

From: "Thomas Schmitt" <scdbackup%gmx.net@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc: 
Subject: Re: kern/48852 CD9660 RockRidge: device files not properly handled
Date: Fri, 30 May 2014 10:35:02 +0200

 Hi,
 
 (Please Cc: me with replies, as i am not subscribed to kern
  bugs. If a bystander can cause this bug thread to show up in
  my mail box, then please do.)
 
 I am currently enhancing cd9660 for multi-session and large
 data files. In the course of this i did test block device
 reading through ISO 9660 + Rock Ridge, with an ISO created
 by my program xorriso (pkgsrc package libisoburn [1]).
 
 The device file is shown by ls -l as
   br--------  1 thomas  operator  0, 12 May 14 14:33 /mnt/iso/dev/wd1e
 and delivers data which match the MD5 of the same amount
 read directly from the original /dev/wd1e
   brw-r--r--  1 root  operator  0, 12 May 14 14:33 /dev/wd1e
 
 Being a competitor of makefs(1), i will not flatly point to it
 now, before i can show a culprit in source code.
 Nevertheless it is already known to produce faulty Rock Ridge
 information.
 E.g. if you load NetBSD-6.1.3-i386.iso in xorriso, you get
   libisofs: WARNING : Invalid TF entry
   libisofs: NOTE :  > Caused by: Wrong or damaged Rock Ridge entry
 
 A problem with device numbers would be in PN entries, though.
 
 To produce a test ISO by xorriso:
 
   xorriso \
      -outdev /dvdbuffer/dev_wd1e.iso \
      -map /dev/wd1e /dev/wd1e \
      -chown thomas /dev/wd1e -- \
      -chmod a-wx,go-r,u+r /dev/wd1e --
 
 usable by
 
   vnconfig -c vnd0 /dvdbuffer/dev_wd1e.iso
   mount_cd9660 /dev/vnd0d /mnt/iso
   ls -l /mnt/iso/dev
 
 yields
 
   br--------  1 thomas  operator  0, 12 May 14 14:33 wd1e
 
 (It is dangerous to omit -o nodev when mounting ISO with valid
  device nodes as superuser. I reduced the risk by taking away
  permissions inside the ISO.)
 
 The content seems ok:
 
   $ dd if=/mnt/iso/dev/wd1e bs=2048 count=1000 | md5
   50e4800cfae73e103eda08dfa061b6da
 
   $ dd if=/dev/wd1e bs=2048 count=1000 | md5
   50e4800cfae73e103eda08dfa061b6da
 
 I will now have a look into makefs (which i cannot compile
 due to API problems between NetBSD-6.1.3 and 6.99.40).
 
 Have a nice day :)
 
 Thomas
 
 [1] If not from pkgsrc, you may get a xorriso tarball from
       http://scdbackup.sourceforge.net/xorriso-1.3.6.pl01.tar.gz
     Compile by
       tar xzf xorriso-1.3.6.pl01.tar.gz
       cd  xorriso-1.3.6
       ./configure && make
     Then runnable without installation as
       xorriso/xorriso ...arguments...
 


Home | Main Index | Thread Index | Old Index