kern/151989: geli version check

yamayan yamayan at wind.sannet.ne.jp
Sat Nov 6 17:40:08 UTC 2010


>Number:         151989
>Category:       kern
>Synopsis:       geli version check
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Nov 06 17:40:07 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator:     yamayan
>Release:        9.0-CURRENT
>Organization:
>Environment:
FreeBSD genius 9.0-CURRENT FreeBSD 9.0-CURRENT #0 r214545M: Sat Oct 30 14:34:42 JST 2010     root at genius:/usr/obj/usr/src/sys/NYANCO  amd64

>Description:
geli version check accept ONLY newest metadata.
older geli disk cannot attach.
>How-To-Repeat:
older version geli init disk without -b option.
newest version geli attach disk.
>Fix:
geli version check in g_eli_config(sys/geom/eli/g_eli_ctl.c)
  accept older version as same as g_eli_taste(g_eli.c).


Patch attached with submission follows:

--- sys/geom/eli/g_eli_ctl.c.orig	2010-11-06 01:19:09.000000000 +0900
+++ sys/geom/eli/g_eli_ctl.c	2010-11-06 01:20:37.000000000 +0900
@@ -1017,7 +1017,7 @@
 		gctl_error(req, "No '%s' argument.", "version");
 		return;
 	}
-	if (*version != G_ELI_VERSION) {
+	if (*version > G_ELI_VERSION) {
 		gctl_error(req, "Userland and kernel parts are out of sync.");
 		return;
 	}


>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-bugs mailing list