https://bugs.winehq.org/show_bug.cgi?id=55239
Bug ID: 55239 Summary: Read access denied for device L"\??\f:\", FS volume label and serial are not available Product: Wine Version: 8.12 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: kernel32 Assignee: wine-bugs@winehq.org Reporter: conurus@gmail.com Distribution: ---
Under ./wine/dosdevices, there are a bunch of symbolic links to each removable drive. My D: links to /dev/sdb. Now I don't have access to /dev/sdb whatsoever, not even read access, which is correct from a security standpoint, otherwise any user can circumvent any access control and peer at any other users' data by low level disk access.
Reading just the volume label and serial should be legal and permitted, so I believe this is not a feature but a bug. In my case the underlying Win32 API call I used is GetVolumeInformation. There must be some way for wine to implement this call without low level disk access.
Forum topic: https://forum.winehq.org/viewtopic.php?t=37602
https://bugs.winehq.org/show_bug.cgi?id=55239
Fabian Maurer dark.shadow4@web.de changed:
What |Removed |Added ---------------------------------------------------------------------------- Ever confirmed|0 |1 CC| |dark.shadow4@web.de Status|UNCONFIRMED |NEEDINFO
--- Comment #1 from Fabian Maurer dark.shadow4@web.de --- Most likely a dupe of 53012. Is there any issue this causes?
Unless you're sure there is something wrong with GetVolumeInformation, this isn't a bug.
https://bugs.winehq.org/show_bug.cgi?id=55239
conurus@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |DUPLICATE Status|NEEDINFO |RESOLVED
--- Comment #2 from conurus@gmail.com --- You are right. Dup of 53012. I will go over there. Thank you!
*** This bug has been marked as a duplicate of bug 53012 ***
https://bugs.winehq.org/show_bug.cgi?id=55239
conurus@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Resolution|DUPLICATE |--- Status|RESOLVED |REOPENED
--- Comment #3 from conurus@gmail.com --- Wait. I went over to 53012, which is a harmless warning in the log. But my Windows app is having an actual loss of functionality (compared to Windows). GetVolumeInformation is actually returning an error and causing my app which reads a removable hard drive to fail. I will gather more information and get back. Thanks.
https://bugs.winehq.org/show_bug.cgi?id=55239
Zeb Figura z.figura12@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |z.figura12@gmail.com
--- Comment #4 from Zeb Figura z.figura12@gmail.com --- Are you sure GetVolumeInformation() is failing because it can't detect the label and serial? We should fall back to just returning a bogus/empty label and serial.
https://bugs.winehq.org/show_bug.cgi?id=55239
Olivier F. R. Dierick o.dierick@piezo-forte.be changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |o.dierick@piezo-forte.be
--- Comment #5 from Olivier F. R. Dierick o.dierick@piezo-forte.be --- (In reply to conurus from bug 53012)
Thank you very much. I wrote a Windows app that requires reading the volume label of a removable drive to function correctly, that worked on neither macOS nor Linux with wine. In winecfg, the "Label" is blank, but the UI does not allow me to set it at all.
What I am hoping for is pretty much for wine explorer.exe to be able to show labels for removable media such as SD cards, which it currently shows nothing because the label is blank.
The mount point path contains the volume label. e.g. if /Volume/SDCard is drive J:\ then GetVolumeInformation could return SDCard?
I do see all the partition labels (e.g. EFI) in wine explorer.exe.
It is very confusing that there is both a partition label and a filesystem label. Wine is getting the partition label only. This is not good in the sense that Windows uses both, not just the former.
Hello,
The 'Read access denied for device' error message may be misleading in some case depending on what the 'dosdevice' is linked to (directory vs real device). My patch in bug 53012 is meant to address that by suppressing the error message for devices linked to a directory (Z: → '/' for example).
A WINEDEBUG=+file,+volume debugging log will tell us more about what GetVolumeInformation is doing.
Please attach (don't paste) the debugging log to this bug. Instructions to get a log can be found there: https://wiki.winehq.org/FAQ#get_log
Regards.
https://bugs.winehq.org/show_bug.cgi?id=55239
--- Comment #6 from conurus@gmail.com --- Created attachment 74842 --> https://bugs.winehq.org/attachment.cgi?id=74842 Volume label of a SD card is blank
WINEDEBUG=+file,+volume,+mountmgr wine64 explorer.exe Go to My Computer, I: (drive letter of the SD card) The log before I clicked on "I:" is omitted
[first attempt at dosdevices/i::, two colons, in the trace] mountmgr is the one trying to deduce the volume label from the boot sector using low-level disk access. (dlls/mountmgr.sys/device.c, VOLUME_ReadFATSuperblock) We know that it is bound to fail (permission denied) and we think it is harmless.
[Fallback to dosdevices/i: (single colon)] I don't think the fallback case find any volume label either, but returns a blank string. It seems like the fallback case expects .windows-label to contain the volume label.
https://bugs.winehq.org/show_bug.cgi?id=55239
Olivier F. R. Dierick o.dierick@piezo-forte.be changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |mywine@schiermeier-it.de
--- Comment #7 from Olivier F. R. Dierick o.dierick@piezo-forte.be --- *** Bug 56727 has been marked as a duplicate of this bug. ***