Re: partially encrypted filesystem

From: David Woodhouse
Date: Mon Dec 08 2003 - 06:29:28 EST


On Thu, 2003-12-04 at 18:20 +0000, Phillip Lougher wrote:
> Considering that Jffs2 is the only writeable compressed filesystem, yes.
> What should be borne in mind is compressed filesystems never expect
> the data after compression to be bigger than the original data.

In fact that assumption is fairly trivial to remove, if you can put an
upper bound on the growth. Adding encryption of data to JFFS2 would
actually be fairly trivial; encryption of metadata would be harder.

You could do it without touching or grokking the core of JFFS2 at all --
just poke at fs/jffs2/compr.c and note that you're expected to eat as
much of the input as will fit into the output buffer, returning success
even if it didn't all fit.

--
dwmw2

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/