grub/grub-core/fs
Pali Rohár 435fa75e01 * grub-core/fs/udf.c: Add support for UUID
Use same algorithm as in libblkid from util-linux v2.30.

1. Take first 16 bytes from UTF-8 encoded string of VolumeSetIdentifier
2. If all bytes are hexadecimal digits, convert to lowercase and use as UUID
3. If first 8 bytes are not all hexadecimal digits, convert those 8 bytes
   to their hexadecimal representation, resulting in 16 bytes for UUID
4. Otherwise, compose UUID from two parts:
   1. part: converted first 8 bytes (which are hexadecimal digits) to lowercase
   2. part: encoded following 4 bytes to their hexadecimal representation (16 bytes)

So UUID would always have 16 hexadecimal digits in lowercase variant.

According to UDF specification, first 16 Unicode characters of
VolumeSetIdentifier should be unique value and first 8 should be
hexadecimal characters.

In most cases all 16 characters are hexadecimal, but e.g. MS Windows
format.exe set only first 8 as hexadecimal and remaining as fixed
(non-unique) which violates specification.
2017-08-07 17:51:50 +02:00
..
zfs zfs: remove size_t typedef and use grub_size_t instead 2017-08-07 16:21:15 +02:00
affs.c Add gcc_struct to all packed structures when compiling with mingw. 2013-12-15 14:14:30 +01:00
afs.c Leverage BFS implementation to read AFS. 2011-10-30 16:10:18 +01:00
archelp.c archelp: Never pass NULL as mtime. 2015-07-27 13:19:02 +02:00
bfs.c BFS: Convert to fshelp. 2015-07-27 12:48:38 +02:00
btrfs.c btrfs: avoid "used uninitialized" error with GCC7 2017-04-04 19:22:32 +03:00
cbfs.c cbfs: Fix corner case and compilation with recdent gcc 2015-11-09 03:24:04 +01:00
cpio.c Add gcc_struct to all packed structures when compiling with mingw. 2013-12-15 14:14:30 +01:00
cpio_be.c Add gcc_struct to all packed structures when compiling with mingw. 2013-12-15 14:14:30 +01:00
cpio_common.c fs/{cbfs,cpio}: Remove useless check if mode is NULL. 2015-01-27 16:32:21 +01:00
exfat.c exfat reader 2011-04-11 18:13:00 +02:00
ext2.c Allow GRUB to mount ext2/3/4 filesystems that have the encryption feature. 2017-06-29 13:29:53 +00:00
fat.c exfat: Support files over 4GiB 2017-01-27 22:10:21 +00:00
fshelp.c fshelp: Add handling of "." and ".." and grub_fshelp_find_file_lookup. 2015-07-27 12:45:35 +02:00
hfs.c hfs: fix memory leak 2016-01-09 11:36:42 +03:00
hfsplus.c Add missing initializers to silence suprious warnings. 2015-03-27 14:44:41 +01:00
hfspluscomp.c Make grub_zlib_decompress handle incomplete chunks. 2013-12-18 23:39:49 +01:00
iso9660.c Remove the variable oldname which is attempting to free stack space. 2016-03-15 22:04:38 +03:00
jfs.c Add gcc_struct to all packed structures when compiling with mingw. 2013-12-15 14:14:30 +01:00
minix.c fs/minix: Fix sector promotion to 64-bit. 2015-01-25 20:32:31 +01:00
minix2.c Split minix.mod into minix.mod and minix2.mod. 2010-09-08 19:13:48 +02:00
minix2_be.c Handle big-endian minixfs (fixes minixfs tests on bigendian). 2012-04-01 21:35:18 +02:00
minix3.c minix3fs support 2011-04-11 08:16:13 +02:00
minix3_be.c Handle big-endian minixfs (fixes minixfs tests on bigendian). 2012-04-01 21:35:18 +02:00
minix_be.c Handle big-endian minixfs (fixes minixfs tests on bigendian). 2012-04-01 21:35:18 +02:00
newc.c Add gcc_struct to all packed structures when compiling with mingw. 2013-12-15 14:14:30 +01:00
nilfs2.c Reject NILFS2 superblocks with over 1GiB blocks. 2015-01-21 17:42:10 +01:00
ntfs.c fs/ntfs: Add sizes sanity checks. 2015-01-25 20:32:31 +01:00
ntfscomp.c Fix warnings when compiling with -O3 2016-02-17 17:56:41 +01:00
odc.c Add gcc_struct to all packed structures when compiling with mingw. 2013-12-15 14:14:30 +01:00
proc.c Switch procfs to use archelp. 2015-07-27 12:44:19 +02:00
reiserfs.c reiserfs: Fix handling of first entry in the directory. 2015-07-24 01:23:45 +02:00
romfs.c Remove nested functions from disk and file read hooks. 2013-02-27 17:19:15 +01:00
sfs.c fs/sfs: Fix error check and add sanity check. 2015-01-25 20:32:31 +01:00
squash4.c squash4: fix handling of fragments and sparse files 2017-02-24 19:10:43 +03:00
tar.c Add gcc_struct to all packed structures when compiling with mingw. 2013-12-15 14:14:30 +01:00
udf.c * grub-core/fs/udf.c: Add support for UUID 2017-08-07 17:51:50 +02:00
ufs.c ufs: Fix parameters to grub_memset. 2015-10-09 13:35:40 +02:00
ufs2.c automake commit without merge history 2010-05-06 11:34:04 +05:30
ufs_be.c Support big-endian UFS1. 2012-12-08 20:56:58 +01:00
xfs.c xfs: accept filesystem with meta_uuid 2016-07-26 20:29:26 +03:00