From jr@opal.com  Mon Nov 17 17:42:17 2008
Return-Path: <jr@opal.com>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 2E6511065670
	for <FreeBSD-gnats-submit@freebsd.org>; Mon, 17 Nov 2008 17:42:17 +0000 (UTC)
	(envelope-from jr@opal.com)
Received: from smtp.vzavenue.net (smtp.vzavenue.net [66.171.59.140])
	by mx1.freebsd.org (Postfix) with ESMTP id D19548FC1C
	for <FreeBSD-gnats-submit@freebsd.org>; Mon, 17 Nov 2008 17:42:16 +0000 (UTC)
	(envelope-from jr@opal.com)
Received: from 74.79.171.66.subscriber.vzavenue.net (HELO homobox.opal.com) ([66.171.79.74])
  by smtp.vzavenue.net with ESMTP; 17 Nov 2008 12:42:11 -0500
Received: from vougeot.opal.com (localhost [127.0.0.1])
	(authenticated bits=0)
	by homobox.opal.com (8.14.2/8.14.2) with ESMTP id mAHHgAIj097725
	for <FreeBSD-gnats-submit@freebsd.org>; Mon, 17 Nov 2008 12:42:10 -0500 (EST)
	(envelope-from jr@opal.com)
Received: from vougeot.opal.com ([72.68.192.15] helo=vougeot.opal.com) by
	ASSP-nospam; 17 Nov 2008 12:42:10 -0500
Received: from vougeot.opal.com (localhost [127.0.0.1])
	by vougeot.opal.com (8.14.2/8.14.2) with ESMTP id mAHHggmM089358
	for <FreeBSD-gnats-submit@freebsd.org>; Mon, 17 Nov 2008 12:42:48 -0500 (EST)
	(envelope-from jr@opal.com)
Received: (from jr@localhost)
	by vougeot.opal.com (8.14.2/8.14.2/Submit) id mAHHgfvj089357;
	Mon, 17 Nov 2008 12:42:42 -0500 (EST)
	(envelope-from jr)
Message-Id: <200811171742.mAHHgfvj089357@vougeot.opal.com>
Date: Mon, 17 Nov 2008 12:42:42 -0500 (EST)
From: "J.R. Oldroyd" <fbsd@opal.com>
Reply-To: "J.R. Oldroyd" <fbsd@opal.com>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: cd9660 driver to accept IEEE_P1282 and IEEE_1282 tagged images [patch]
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         128942
>Category:       kern
>Synopsis:       [cd9660] [patch] cd9660 driver to accept IEEE_P1282 and IEEE_1282 tagged images [patch]
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Nov 17 17:50:01 UTC 2008
>Closed-Date:    Sat Nov 29 05:45:07 UTC 2008
>Last-Modified:  Sat Nov 29 05:45:07 UTC 2008
>Originator:     J.R. Oldroyd
>Release:        FreeBSD 7.1-PRERELEASE i386
>Organization:
>Environment:
System: FreeBSD vougeot.opal.com 7.1-PRERELEASE FreeBSD 7.1-PRERELEASE #9: Wed Oct 29 21:37:25 EDT 2008 xx@vougeot.opal.com:/usr/src/sys/i386/compile/VOUGEOT i386
>Description:
The FreeBSD cd9660 driver looks for the string "RRIP_1991A" in the Rock
Ridge Extensions Record "ER".  In 1994, the Rock Ridge Interchange Protocol
standard was adopted as IEEE draft 1282 and then as IEEE standard 1282.  This
added strings "IEEE_P1282" and "IEEE_1282" as acceptable values for the ER
record.  The FreeBSD driver is now - ahem - 14 years behind in recognising
this.  The patch below updates the driver to accept all three ER
identification strings.

A similar change already exists in the NetBSD cd9660 driver.
>How-To-Repeat:
Create an ISO image using a libisofs-based application which emits the tag
IEEE_1282 in the ER record.  Mount it.  Observe that no Rock Ridge info is
visible when listing files in that filesystem.
>Fix:
--- fs/cd9660/cd9660_rrip.c.orig	2007-02-11 08:54:25.000000000 -0500
+++ fs/cd9660/cd9660_rrip.c	2008-11-16 23:14:17.000000000 -0500
@@ -467,8 +467,12 @@
 	ISO_RRIP_EXTREF *p;
 	ISO_RRIP_ANALYZE *ana;
 {
-	if (isonum_711(p->len_id) != 10
-	    || bcmp((char *)p + 8,"RRIP_1991A",10)
+	if ( ! ((isonum_711(p->len_id) == 10
+		&& bcmp((char *)p + 8,"RRIP_1991A",10) == 0)
+	     || (isonum_711(p->len_id) == 10
+		&& bcmp((char *)p + 8,"IEEE_P1282",10) == 0)
+	     || (isonum_711(p->len_id) ==  9
+		&& bcmp((char *)p + 8,"IEEE_1282",  9) == 0))
 	    || isonum_711(p->version) != 1)
 		return 0;
 	ana->fields &= ~ISO_SUSP_EXTREF;
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: lulf 
State-Changed-When: Wed Nov 26 13:10:09 UTC 2008 
State-Changed-Why:  
Committed, thanks! 


http://www.freebsd.org/cgi/query-pr.cgi?pr=128942 
State-Changed-From-To: closed->patched 
State-Changed-By: kientzle 
State-Changed-When: Sat Nov 29 05:44:06 UTC 2008 
State-Changed-Why:  

http://www.freebsd.org/cgi/query-pr.cgi?pr=128942 
State-Changed-From-To: patched->closed 
State-Changed-By: kientzle 
State-Changed-When: Sat Nov 29 05:44:44 UTC 2008 
State-Changed-Why:  
Fixed in 7-STABLE and RELENG-7.1 now. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=128942 
>Unformatted:
