lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <787b0d920705091649m76d5f5f4m9768a6862b048659@mail.gmail.com>
Date:	Wed, 9 May 2007 19:49:42 -0400
From:	"Albert Cahalan" <acahalan@...il.com>
To:	"Andrey Borzenkov" <arvidjaar@...l.ru>
Cc:	"Jan Engelhardt" <jengelh@...ux01.gwdg.de>,
	hirofumi@...l.parknet.co.jp, linux-kernel@...r.kernel.org,
	hpa@...or.com
Subject: Re: Long file names in VFAT broken with iocharset=utf8

On 5/9/07, Andrey Borzenkov <arvidjaar@...l.ru> wrote:
> On Wednesday 09 May 2007, Albert Cahalan wrote:
...
>>> On May 8 2007 00:43, Albert Cahalan wrote:

>>>> Fix: the vfat driver should use the 8.3 name for such files.
...
>> It's not appropriate for vfat, HPFS, JFS, or NTFS. All of those
>> have built-in support for 8.3 aliases. Normally the 8.3 names
>> are like hidden hard links, except that deletion of either name
>> will wipe out the other. (same as case differences too)
>> So the names are there, and they should already work.
>> They just need to be reported for directory listings when the
>> long names would be too long.
>
> several problems associated with it
>
> 1. those names are rather meaningless. How do you find out which file they
> refer to? It is OK for trivial cases but not in a directory full of long
> names; nor am I sure how many unique short names can be generated.

If a short name can not be generated, then no OS could
create the file at all. The vfat and iso9660 filesystems require
short names. Any OS writing to such a filesystem MUST
generate short names in addition to any long names.
Mount your vfat as filesystem type "msdos" to see.

By default, Windows will also generate short names on NTFS.

Note that you can't put your files on a CD-ROM in a way
that Windows could read the filenames. Windows limits
CD-ROM filenames to 63 characters; you get at most 103
if you violate the spec.

> 2. directory contents is effectively invalidated upon backup and restore (tar
> c; rm -rf; tar x). It is impossible to infer long names from short ones.

It may be that tar fails to use the vfat ioctl calls to save
and restore short names. You could try using Wine to
run a Windows-native backup program. This shouldn't
really matter though; you'd only be getting short names
for files that had truly unreasonable long names anyway.

I suppose somebody should check to see if there is a
danger of overwrite when the short-named files get
written back. The safest thing might be to mount the
filesystem as type "msdos".

> 3. this still does not answer how can I *create* long name from within Linux.

WTF? These names are too annoying to use, even if there
weren't this limit. Anything over about 29 characters is in
need of a rename. (that'd be 58 bytes for you, which is OK)
The limit is already 4 times larger than what is reasonable.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ