mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
* commandline:
* DiscImageChef.Filesystems/FAT.cs: Correct null volume label and oem string * DiscImageChef.Filesystems/NTFS.cs: Some NTFS do not contain signature1. * DiscImageChef.Metadata/MediaType.cs: Added XML name for iomega ZIP. * DiscImageChef/Commands/Analyze.cs: * DiscImageChef/Commands/CreateSidecar.cs: Check multiple partitioning schemes. * DiscImageChef/Commands/DumpMedia.cs: Check multiple partitioning schemes. Do not add interface data to sidecar for removable devices. Add dump hardware to sidecar for remocable block devices.
This commit is contained in:
@@ -1,3 +1,8 @@
|
|||||||
|
2016-02-05 Natalia Portillo <claunia@claunia.com>
|
||||||
|
|
||||||
|
* commandline:
|
||||||
|
|
||||||
|
|
||||||
2016-02-04 Natalia Portillo <claunia@claunia.com>
|
2016-02-04 Natalia Portillo <claunia@claunia.com>
|
||||||
|
|
||||||
* commandline:
|
* commandline:
|
||||||
|
|||||||
@@ -1,3 +1,11 @@
|
|||||||
|
2016-02-05 Natalia Portillo <claunia@claunia.com>
|
||||||
|
|
||||||
|
* FAT.cs:
|
||||||
|
Correct null volume label and oem string
|
||||||
|
|
||||||
|
* NTFS.cs:
|
||||||
|
Some NTFS do not contain signature1.
|
||||||
|
|
||||||
2016-02-04 Natalia Portillo <claunia@claunia.com>
|
2016-02-04 Natalia Portillo <claunia@claunia.com>
|
||||||
|
|
||||||
* FFS.cs:
|
* FFS.cs:
|
||||||
|
|||||||
@@ -244,7 +244,7 @@ namespace DiscImageChef.Plugins
|
|||||||
|
|
||||||
dosString = new byte[8];
|
dosString = new byte[8];
|
||||||
Array.Copy(bpb_sector, 0x03, dosString, 0, 8);
|
Array.Copy(bpb_sector, 0x03, dosString, 0, 8);
|
||||||
BPB.OEMName = Encoding.ASCII.GetString(dosString);
|
BPB.OEMName = StringHandlers.CToString(dosString);
|
||||||
BPB.bps = BitConverter.ToUInt16(bpb_sector, 0x0B);
|
BPB.bps = BitConverter.ToUInt16(bpb_sector, 0x0B);
|
||||||
BPB.spc = bpb_sector[0x0D];
|
BPB.spc = bpb_sector[0x0D];
|
||||||
BPB.rsectors = BitConverter.ToUInt16(bpb_sector, 0x0E);
|
BPB.rsectors = BitConverter.ToUInt16(bpb_sector, 0x0E);
|
||||||
@@ -272,10 +272,10 @@ namespace DiscImageChef.Plugins
|
|||||||
FAT32PB.serial_no = BitConverter.ToUInt32(bpb_sector, 0x43);
|
FAT32PB.serial_no = BitConverter.ToUInt32(bpb_sector, 0x43);
|
||||||
dosString = new byte[11];
|
dosString = new byte[11];
|
||||||
Array.Copy(bpb_sector, 0x47, dosString, 0, 11);
|
Array.Copy(bpb_sector, 0x47, dosString, 0, 11);
|
||||||
FAT32PB.volume_label = Encoding.ASCII.GetString(dosString);
|
FAT32PB.volume_label = StringHandlers.CToString(dosString);
|
||||||
dosString = new byte[8];
|
dosString = new byte[8];
|
||||||
Array.Copy(bpb_sector, 0x52, dosString, 0, 8);
|
Array.Copy(bpb_sector, 0x52, dosString, 0, 8);
|
||||||
FAT32PB.fs_type = Encoding.ASCII.GetString(dosString);
|
FAT32PB.fs_type = StringHandlers.CToString(dosString);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -285,10 +285,10 @@ namespace DiscImageChef.Plugins
|
|||||||
EPB.serial_no = BitConverter.ToUInt32(bpb_sector, 0x27);
|
EPB.serial_no = BitConverter.ToUInt32(bpb_sector, 0x27);
|
||||||
dosString = new byte[11];
|
dosString = new byte[11];
|
||||||
Array.Copy(bpb_sector, 0x2B, dosString, 0, 11);
|
Array.Copy(bpb_sector, 0x2B, dosString, 0, 11);
|
||||||
EPB.volume_label = Encoding.ASCII.GetString(dosString);
|
EPB.volume_label = StringHandlers.CToString(dosString);
|
||||||
dosString = new byte[8];
|
dosString = new byte[8];
|
||||||
Array.Copy(bpb_sector, 0x36, dosString, 0, 8);
|
Array.Copy(bpb_sector, 0x36, dosString, 0, 8);
|
||||||
EPB.fs_type = Encoding.ASCII.GetString(dosString);
|
EPB.fs_type = StringHandlers.CToString(dosString);
|
||||||
}
|
}
|
||||||
|
|
||||||
sb.AppendFormat("OEM Name: {0}", BPB.OEMName).AppendLine();
|
sb.AppendFormat("OEM Name: {0}", BPB.OEMName).AppendLine();
|
||||||
@@ -335,6 +335,7 @@ namespace DiscImageChef.Plugins
|
|||||||
}
|
}
|
||||||
|
|
||||||
sb.AppendFormat("Volume label: {0}", EPB.volume_label).AppendLine();
|
sb.AppendFormat("Volume label: {0}", EPB.volume_label).AppendLine();
|
||||||
|
if(!string.IsNullOrEmpty(EPB.volume_label))
|
||||||
xmlFSType.VolumeName = EPB.volume_label;
|
xmlFSType.VolumeName = EPB.volume_label;
|
||||||
sb.AppendFormat("Filesystem type: {0}", EPB.fs_type).AppendLine();
|
sb.AppendFormat("Filesystem type: {0}", EPB.fs_type).AppendLine();
|
||||||
}
|
}
|
||||||
@@ -354,6 +355,7 @@ namespace DiscImageChef.Plugins
|
|||||||
}
|
}
|
||||||
|
|
||||||
sb.AppendFormat("Volume label: {0}", EPB.volume_label).AppendLine();
|
sb.AppendFormat("Volume label: {0}", EPB.volume_label).AppendLine();
|
||||||
|
if(!string.IsNullOrEmpty(EPB.volume_label))
|
||||||
xmlFSType.VolumeName = EPB.volume_label;
|
xmlFSType.VolumeName = EPB.volume_label;
|
||||||
sb.AppendFormat("Filesystem type: {0}", EPB.fs_type).AppendLine();
|
sb.AppendFormat("Filesystem type: {0}", EPB.fs_type).AppendLine();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -57,8 +57,8 @@ namespace DiscImageChef.Plugins
|
|||||||
return false;
|
return false;
|
||||||
|
|
||||||
byte[] eigth_bytes = new byte[8];
|
byte[] eigth_bytes = new byte[8];
|
||||||
byte signature1, fats_no;
|
byte fats_no;
|
||||||
UInt16 spfat, signature2;
|
UInt16 spfat, signature;
|
||||||
string oem_name;
|
string oem_name;
|
||||||
|
|
||||||
byte[] ntfs_bpb = imagePlugin.ReadSector(0 + partitionStart);
|
byte[] ntfs_bpb = imagePlugin.ReadSector(0 + partitionStart);
|
||||||
@@ -79,15 +79,9 @@ namespace DiscImageChef.Plugins
|
|||||||
if (spfat != 0)
|
if (spfat != 0)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
signature1 = ntfs_bpb[0x026];
|
signature = BitConverter.ToUInt16(ntfs_bpb, 0x1FE);
|
||||||
|
|
||||||
if (signature1 != 0x80)
|
|
||||||
return false;
|
|
||||||
|
|
||||||
signature2 = BitConverter.ToUInt16(ntfs_bpb, 0x1FE);
|
|
||||||
|
|
||||||
return signature2 == 0xAA55;
|
|
||||||
|
|
||||||
|
return signature == 0xAA55;
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void GetInformation(ImagePlugins.ImagePlugin imagePlugin, ulong partitionStart, ulong partitionEnd, out string information)
|
public override void GetInformation(ImagePlugins.ImagePlugin imagePlugin, ulong partitionStart, ulong partitionEnd, out string information)
|
||||||
|
|||||||
@@ -1,3 +1,8 @@
|
|||||||
|
2016-02-05 Natalia Portillo <claunia@claunia.com>
|
||||||
|
|
||||||
|
* MediaType.cs:
|
||||||
|
Added XML name for iomega ZIP.
|
||||||
|
|
||||||
2016-02-04 Natalia Portillo <claunia@claunia.com>
|
2016-02-04 Natalia Portillo <claunia@claunia.com>
|
||||||
|
|
||||||
* Dimensions.cs:
|
* Dimensions.cs:
|
||||||
|
|||||||
@@ -652,6 +652,18 @@ namespace DiscImageChef.Metadata
|
|||||||
DiscType = "CD";
|
DiscType = "CD";
|
||||||
DiscSubType = "3DO";
|
DiscSubType = "3DO";
|
||||||
break;
|
break;
|
||||||
|
case CommonTypes.MediaType.ZIP100:
|
||||||
|
DiscType = "Iomega ZIP";
|
||||||
|
DiscSubType = "Iomega ZIP100";
|
||||||
|
break;
|
||||||
|
case CommonTypes.MediaType.ZIP250:
|
||||||
|
DiscType = "Iomega ZIP";
|
||||||
|
DiscSubType = "Iomega ZIP250";
|
||||||
|
break;
|
||||||
|
case CommonTypes.MediaType.ZIP750:
|
||||||
|
DiscType = "Iomega ZIP";
|
||||||
|
DiscSubType = "Iomega ZIP750";
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
DiscType = "Unknown";
|
DiscType = "Unknown";
|
||||||
DiscSubType = "Unknown";
|
DiscSubType = "Unknown";
|
||||||
|
|||||||
@@ -1,3 +1,14 @@
|
|||||||
|
2016-02-05 Natalia Portillo <claunia@claunia.com>
|
||||||
|
|
||||||
|
* Commands/Analyze.cs:
|
||||||
|
* Commands/CreateSidecar.cs:
|
||||||
|
Check multiple partitioning schemes.
|
||||||
|
|
||||||
|
* Commands/DumpMedia.cs:
|
||||||
|
Check multiple partitioning schemes.
|
||||||
|
Do not add interface data to sidecar for removable devices.
|
||||||
|
Add dump hardware to sidecar for remocable block devices.
|
||||||
|
|
||||||
2016-02-04 Natalia Portillo <claunia@claunia.com>
|
2016-02-04 Natalia Portillo <claunia@claunia.com>
|
||||||
|
|
||||||
* Commands/DumpMedia.cs:
|
* Commands/DumpMedia.cs:
|
||||||
|
|||||||
@@ -124,7 +124,6 @@ namespace DiscImageChef.Commands
|
|||||||
partition_scheme = _partplugin.Name;
|
partition_scheme = _partplugin.Name;
|
||||||
partitions.AddRange(_partitions);
|
partitions.AddRange(_partitions);
|
||||||
Core.Statistics.AddPartition(_partplugin.Name);
|
Core.Statistics.AddPartition(_partplugin.Name);
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -510,9 +510,8 @@ namespace DiscImageChef.Commands
|
|||||||
|
|
||||||
if (_partplugin.GetInformation(_imageFormat, out _partitions))
|
if (_partplugin.GetInformation(_imageFormat, out _partitions))
|
||||||
{
|
{
|
||||||
partitions = _partitions;
|
partitions.AddRange(_partitions);
|
||||||
Core.Statistics.AddPartition(_partplugin.Name);
|
Core.Statistics.AddPartition(_partplugin.Name);
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2030,7 +2030,7 @@ namespace DiscImageChef.Commands
|
|||||||
if (!_imageFormat.OpenImage(options.OutputPrefix + ".bin"))
|
if (!_imageFormat.OpenImage(options.OutputPrefix + ".bin"))
|
||||||
_imageFormat = null;
|
_imageFormat = null;
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch
|
||||||
{
|
{
|
||||||
_imageFormat = null;
|
_imageFormat = null;
|
||||||
}
|
}
|
||||||
@@ -2045,9 +2045,8 @@ namespace DiscImageChef.Commands
|
|||||||
|
|
||||||
if (_partplugin.GetInformation(_imageFormat, out _partitions))
|
if (_partplugin.GetInformation(_imageFormat, out _partitions))
|
||||||
{
|
{
|
||||||
partitions = _partitions;
|
partitions.AddRange(_partitions);
|
||||||
Core.Statistics.AddPartition(_partplugin.Name);
|
Core.Statistics.AddPartition(_partplugin.Name);
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2224,6 +2223,8 @@ namespace DiscImageChef.Commands
|
|||||||
sidecar.BlockMedia[0].Image = new ImageType();
|
sidecar.BlockMedia[0].Image = new ImageType();
|
||||||
sidecar.BlockMedia[0].Image.format = "Raw disk image (sector by sector copy)";
|
sidecar.BlockMedia[0].Image.format = "Raw disk image (sector by sector copy)";
|
||||||
sidecar.BlockMedia[0].Image.Value = options.OutputPrefix + ".bin";
|
sidecar.BlockMedia[0].Image.Value = options.OutputPrefix + ".bin";
|
||||||
|
if (!dev.IsRemovable || dev.IsUSB)
|
||||||
|
{
|
||||||
if (dev.Type == DeviceType.ATAPI)
|
if (dev.Type == DeviceType.ATAPI)
|
||||||
sidecar.BlockMedia[0].Interface = "ATAPI";
|
sidecar.BlockMedia[0].Interface = "ATAPI";
|
||||||
else if (dev.IsUSB)
|
else if (dev.IsUSB)
|
||||||
@@ -2232,6 +2233,7 @@ namespace DiscImageChef.Commands
|
|||||||
sidecar.BlockMedia[0].Interface = "FireWire";
|
sidecar.BlockMedia[0].Interface = "FireWire";
|
||||||
else
|
else
|
||||||
sidecar.BlockMedia[0].Interface = "SCSI";
|
sidecar.BlockMedia[0].Interface = "SCSI";
|
||||||
|
}
|
||||||
sidecar.BlockMedia[0].LogicalBlocks = (long)blocks;
|
sidecar.BlockMedia[0].LogicalBlocks = (long)blocks;
|
||||||
sidecar.BlockMedia[0].LogicalBlockSize = (int)blockSize;
|
sidecar.BlockMedia[0].LogicalBlockSize = (int)blockSize;
|
||||||
sidecar.BlockMedia[0].Manufacturer = dev.Manufacturer;
|
sidecar.BlockMedia[0].Manufacturer = dev.Manufacturer;
|
||||||
@@ -2240,6 +2242,23 @@ namespace DiscImageChef.Commands
|
|||||||
sidecar.BlockMedia[0].Size = (long)(blocks * blockSize);
|
sidecar.BlockMedia[0].Size = (long)(blocks * blockSize);
|
||||||
if (xmlFileSysInfo != null)
|
if (xmlFileSysInfo != null)
|
||||||
sidecar.BlockMedia[0].FileSystemInformation = xmlFileSysInfo;
|
sidecar.BlockMedia[0].FileSystemInformation = xmlFileSysInfo;
|
||||||
|
|
||||||
|
if (dev.IsRemovable)
|
||||||
|
{
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray = new DumpHardwareType[1];
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0] = new DumpHardwareType();
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0].Extents = new ExtentType[1];
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0].Extents[0] = new ExtentType();
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0].Extents[0].Start = 0;
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0].Extents[0].End = (int)(blocks - 1);
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0].Manufacturer = dev.Manufacturer;
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0].Model = dev.Model;
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0].Revision = dev.Revision;
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0].Software = new SoftwareType();
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0].Software.Name = "DiscImageChef";
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0].Software.OperatingSystem = dev.PlatformID.ToString();
|
||||||
|
sidecar.BlockMedia[0].DumpHardwareArray[0].Software.Version = typeof(MainClass).Assembly.GetName().Version.ToString();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user