clalancette / pycdlib

Python library to read and write ISOs
GNU Lesser General Public License v2.1
147 stars 38 forks source link

dot is also allowed #79

Closed zhang20054460 closed 2 years ago

zhang20054460 commented 2 years ago

https://github.com/clalancette/pycdlib/blob/5b341b35a5846a24349227c04cd6e81561dee3fc/pycdlib/pycdlib.py#L69

please reference: https://wiki.osdev.org/ISO_9660#Filenames

Filenames Filenames must use d-character encoding (strD), plus dot and semicolon which have to occur exactly once per filename. Filenames are composed of a File Name, a dot, a File Name Extension, a semicolon; and a version number in decimal digits. The latter two are usually not displayed to the user.

There are three Levels of Interchange defined. Level 1 allows filenames with a File Name length of 8 and an extension length of 3 (like MS-DOS). Levels 2 and 3 allow File Name and File Name Extension to have a combined length of up to 30 characters.

The ECMA-119 Directory Record format can hold composed names of up to 222 characters. This would violate the specs but must nevertheless be handled by a reader of the filesystem.

clalancette commented 2 years ago

So if you look at the code that actually does the checking in https://github.com/clalancette/pycdlib/blob/master/pycdlib/pycdlib.py#L116-L171 , you'll see that it does allow for the dot; it just looks at it in a different place.

To be concrete here, do you have an example of a filename (or an ISO with a filename) that is allowed by the specification, but that pycdlib doesn't support?

clalancette commented 2 years ago

No response to my last comment in a long time, so I'm going to close this out. If you do find a file that is a problem, please feel free to reopen and we can see what the problem is.