WoeUSB / WoeUSB-ng

WoeUSB-ng is a simple tool that enable you to create your own usb stick windows installer from an iso image or a real DVD. This is a rewrite of original WoeUSB.
GNU General Public License v3.0
1.57k stars 131 forks source link

This app uglifying cyrillic file names #75

Open Flashwalker opened 2 years ago

Flashwalker commented 2 years ago

EDIT: @brlin-tw : Fix Markdown markup

Issue Reproduce Instructions

  1. Launch WoeUSB by running woeusbgui
  2. Write windows image

Expected Behavior

Nice file names

Current Behavior

Ugly cyrillic file names like: Показать стиль диска

Info of My Environment

WoeUSB Version

0.2.10-2

WoeUSB Source

Installed from PyPi

Information about the Operating System

Pop!_OS 20.04 LTS x64

Information about the Source Media

"Windows 10"

Information about the Target Device

SP SD card 8GB (USB 3.0 cardrider)

brlin-tw commented 2 years ago

Seems to be related to FAT File System Filename Mojibake Issue · WoeUSB/WoeUSB Wiki

brlin-tw commented 2 years ago

The mount command call here:

https://github.com/WoeUSB/WoeUSB-ng/blob/4d4910b45d164a270c61e856eb2eb2e250dd50ab/WoeUSB/core.py#L437-L439

seems to be lacking appropriate FAT filesystem mount options to avoid mojibake-ing filenames, consider WoeUSB/WoeUSB's implementation:

https://github.com/WoeUSB/WoeUSB/blob/34b400d99d3c4089f487e1d4f7d71970b2d4429e/sbin/woeusb#L1496

Flashwalker commented 2 years ago

I forgot to mention that i used NTFS formated SD card

brlin-tw commented 2 years ago

I forgot to mention that i used NTFS formated SD card

Well then NTFS uses Unicode filenames thus the problem shouldn't happen.

The problem may be due to the incorrect handling of the mounting of the source filesystem, could you try running the following command to mount the original filesystem:

mkdir test_mountpoint
mount \
    --options loop,ro \
    --types udf,iso9660 \
    _source_iso_image_ \
    test_mountpoint

And verify that the filename isn't garbled in the mounted image?

Also, could you try running the Bash version of WoeUSB and verify the problem is still reproduced there?

Flashwalker commented 2 years ago

... And verify that the filename isn't garbled in the mounted image?...

I just tested and file name is ok on mount point http://0x0.st/oT74.png