From: jw schultz <jw@pegasys.ws>
To: linux-kernel@vger.kernel.org
Subject: Re: JFS default behavior
Date: Sun, 15 Feb 2004 22:21:52 -0800 [thread overview]
Message-ID: <20040216062152.GB5192@pegasys.ws> (raw)
In-Reply-To: <1076886183.18571.14.camel@m222.net81-64-248.noos.fr>
On Mon, Feb 16, 2004 at 12:03:03AM +0100, Nicolas Mailhot wrote:
> | Linus Torvalds pointed the way of Tux :
>
> | In short: the kernel talks bytestreams, and that implies that if you
> | want to talk to the kernel, you HAVE TO USE UTF-8.
>
> In that case :
> - should the kernel allow apps to write filenames that are invalid
> UTF-8 and will crash UTF-8 apps ?
Yes. The kernel interface specifies it as a bytesteam with
0x00 and 0x2f having special meaning. That is a constraint,
not a policy. It is user space that determines the policy
of UTF-8.
> UTF-8 and will crash UTF-8 apps ?
Fix the broken apps. Crashing because of "invalid" UTF-8 is
no more excusable than crashing because of a string longer
than expected (buffer overrun). Filenames as read from the
filesystem should be treated just like any other untrusted
input.
> - should this UTF-8 rule be noted somewhere (in a FAQ/man page/LSB spec/
> whatever) so apps authors know they are supposed to read and write UTF-8
> filenames and not apply locale rules to kernel objects ?
Since the LSB spec describes user space it might be a
suitable place.
> - what happens to already existing invalid UTF-8 filenames ? Should the
> kernel forcibly rewrite them (in 2.7.0...) to remove legacy mess ? What
If you have a filesystem with filenames that don't conform
to your policy write userspace tools to detect and/or fix
them. If you have programs creating non-conforming
filenames, fix or rm those programs.
> kernel forcibly rewrite them (in 2.7.0...) to remove legacy mess ? What
> should happen if someone plug an unconverted FS in such a system
> afterwards ?
The kernel won't care. Any user space code that treats the
filenames as something other than bytestreams should be able
to cope with any sequence of bytes.
> These are the questions people have been asking.
OK. The questions have been asked and answered.
Asking again and again and again won't change the answer.
--
________________________________________________________________
J.W. Schultz Pegasystems Technologies
email address: jw@pegasys.ws
Remember Cernan and Schmitt
next prev parent reply other threads:[~2004-02-16 6:21 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-02-15 23:03 JFS default behavior Nicolas Mailhot
2004-02-16 3:45 ` Jan Knutar
2004-02-16 8:30 ` Nicolas Mailhot
2004-02-16 8:54 ` Valdis.Kletnieks
2004-02-16 6:21 ` jw schultz [this message]
2004-02-16 15:55 ` Jamie Lokier
2004-02-17 6:47 ` jw schultz
2004-02-17 21:37 ` Jamie Lokier
2004-02-17 22:12 ` Linus Torvalds
2004-02-18 9:59 ` Jamie Lokier
2004-02-18 15:54 ` Linus Torvalds
2004-02-18 23:58 ` Jamie Lokier
2004-02-19 10:59 ` JFS default behavior / UTF-8 filenames kernel
2004-02-19 14:05 ` Dave Kleikamp
2004-02-19 23:47 ` kernel
2004-02-20 15:00 ` Dave Kleikamp
2004-02-22 19:22 ` kernel
2004-02-24 14:44 ` Dave Kleikamp
[not found] <1pvUz-6j-1@gated-at.bofh.it>
[not found] ` <1pRVj-2am-29@gated-at.bofh.it>
2004-02-16 15:32 ` JFS default behavior Pascal Schmidt
2004-02-16 19:05 ` Eduard Bloch
-- strict thread matches above, loose matches on Subject: below --
2004-02-15 14:48 Pascal Schmidt
2004-02-16 14:24 ` Eduard Bloch
[not found] <04Feb13.163954est.41760@gpu.utcc.utoronto.ca>
2004-02-14 14:27 ` Nicolas Mailhot
2004-02-14 15:40 ` viro
2004-02-14 17:47 ` Nicolas Mailhot
2004-02-14 17:59 ` Nicolas Mailhot
2004-02-14 23:06 ` Robin Rosenberg
2004-02-14 23:29 ` viro
2004-02-15 0:07 ` Robin Rosenberg
2004-02-15 2:41 ` Linus Torvalds
2004-02-15 3:33 ` Matthias Urlichs
2004-02-15 4:04 ` viro
2004-02-15 9:48 ` Robin Rosenberg
2004-02-15 18:26 ` yodaiken
2004-02-12 16:50 JFS default behavior (was: UTF-8 in file systems? xfs/extfs/etc.) Nicolas Mailhot
2004-02-13 3:03 ` Jamie Lokier
2004-02-13 18:06 ` Nicolas Mailhot
2004-02-13 18:15 ` viro
2004-02-13 18:31 ` Richard B. Johnson
2004-02-13 18:50 ` JFS default behavior Ulrich Drepper
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20040216062152.GB5192@pegasys.ws \
--to=jw@pegasys.ws \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox