DiscUtils / DiscUtils

Utility libraries to interact with discs, filesystem formats and more
MIT License
775 stars 181 forks source link

Support file size support more than 4 GB up to 4.3 GB #210

Open atrdev-rgb opened 4 years ago

atrdev-rgb commented 4 years ago

I use Net Core 3.1 When trying to create an iso image with the addition file with size 4.2 GB, the size of the image is 4.2 Gb, but inside image the file itself is smaller - 4.5 Mb.

psychonic commented 3 years ago

I believe this is due to the MultiExtent flag existing but not actually being implemented. A related issue occurs when trying to extract files from an ISO when the file is split across multiple extents. (Most common if file is over 4gb, but not necessarily). Only a partial version of the file gets extracted, without any source of exception thrown.

t3knoid commented 2 years ago

I tried using this to automate extracting of NSRL RDS digest file from NIST. Unfortunately, one of their ISOs is greater than 4GB. Here's a direct link to the ISO file:

https://s3.amazonaws.com/rds.nsrl.nist.gov/RDS/current/RDS_legacy.iso

DiscUtils only sees 8668223 bytes. No exception is thrown.

LTRData commented 2 years ago

I just tried to open that image with UdfReader class and it seems to work correctly after a quick look. I get these files and lengths in it:

Name Length


NSRLFile.txt.hash 111 NSRLFile.txt.zip 4303635519 NSRLMfg.txt 2775978 NSRLOS.txt 62521 NSRLProd.txt 3145083 read_me.txt 1837 signatures.txt 371

t3knoid commented 2 years ago

@LTRData - That's exactly what I need. I was thrown off by the other ISO on the NIST site being able to extract using Iso9660 class. Thanks for the quick answer!

LTRData commented 2 years ago

Sounds perfect! Yes images like this are often not ISO 9660 but instead UDF, so it is worth trying UdfReader too when this happens. They are really very different kinds of file systems but both are frequently called .iso in the image file names for historical reasons.