dissect.volume 3.17.dev3__tar.gz → 3.18.dev1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/PKG-INFO +1 -1
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/disk/partition.py +14 -14
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect.volume.egg-info/PKG-INFO +1 -1
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/disk/test_apm.py +3 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/disk/test_bsd.py +1 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/disk/test_gpt.py +18 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/disk/test_mbr.py +1 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/.git-blame-ignore-revs +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/.gitattributes +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/COPYRIGHT +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/LICENSE +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/MANIFEST.in +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/README.md +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/ddf/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/ddf/c_ddf.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/ddf/c_ddf.pyi +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/ddf/ddf.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/disk/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/disk/disk.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/disk/schemes/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/disk/schemes/apm.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/disk/schemes/bsd.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/disk/schemes/gpt.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/disk/schemes/mbr.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/dm/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/dm/btree.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/dm/c_dm.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/dm/c_dm.pyi +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/dm/thin.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/exceptions.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/ldm.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/lvm/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/lvm/c_lvm2.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/lvm/c_lvm2.pyi +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/lvm/lvm2.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/lvm/metadata.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/lvm/physical.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/md/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/md/c_md.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/md/c_md.pyi +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/md/md.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/raid/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/raid/raid.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/raid/stream.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/vinum/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/vinum/c_vinum.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/vinum/c_vinum.pyi +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/vinum/config.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/vinum/vinum.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/vss.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect.volume.egg-info/SOURCES.txt +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect.volume.egg-info/dependency_links.txt +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect.volume.egg-info/requires.txt +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect.volume.egg-info/top_level.txt +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/pyproject.toml +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/setup.cfg +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid0-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid0-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid0-3.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid0-raid1-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid0-raid1-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid1-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid1-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid10-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid10-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid10-3.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid10-4.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid4-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid4-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid5-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid5-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid5-3.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid6-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid6-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid6-3.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid6-4.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/disk/apm.bin +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/disk/bsd.bin +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/disk/bsd64.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/disk/gpt.bin +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/disk/gpt_4k.bin +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/disk/gpt_esxi.bin +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/disk/gpt_hybrid.bin +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/disk/gpt_no_name_xff.bin +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/disk/mbr.bin +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/dm/dm-thin-data.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/dm/dm-thin-empty-data.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/dm/dm-thin-empty-metadata.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/dm/dm-thin-metadata.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/lvm/lvm-mirror-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/lvm/lvm-mirror-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/lvm/lvm-thin.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/lvm/lvm.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-90-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-90-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-90-raid1-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-90-raid1-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-linear-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-linear-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid0-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid0-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid0-3.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid1-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid1-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid10-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid10-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid4-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid4-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid4-3.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid5-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid5-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid5-3.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid6-1.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid6-2.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid6-3.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/md/md-raid6-4.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-concat_diska.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-concat_diskb.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-mirror_diska.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-mirror_diskb.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-raid5_diska.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-raid5_diskb.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-raid5_diskc.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-raid5_diskd.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-striped_diska.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-striped_diskb.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-stripedmirror_diska.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-stripedmirror_diskb.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-stripedmirror_diskc.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-stripedmirror_diskd.bin.gz +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_docs/Makefile +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_docs/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_docs/conf.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_docs/index.rst +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/conftest.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/ddf/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/ddf/test_ddf.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/disk/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/dm/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/dm/test_dm.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/lvm/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/lvm/test_lvm.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/md/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/md/test_md.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/vinum/__init__.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/vinum/test_config.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/vinum/test_vinum.py +0 -0
- {dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tox.ini +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: dissect.volume
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.18.dev1
|
|
4
4
|
Summary: A Dissect module implementing a parser for different disk volume and partition systems, for example LVM2, GPT and MBR
|
|
5
5
|
Author-email: Dissect Team <dissect@fox-it.com>
|
|
6
6
|
License-Expression: AGPL-3.0-or-later
|
|
@@ -218,27 +218,27 @@ class Partition:
|
|
|
218
218
|
self.name = name
|
|
219
219
|
self.flags = flags
|
|
220
220
|
self.guid = guid
|
|
221
|
-
self.type_str = type_str
|
|
221
|
+
self.type_str = type_str or translate_partition_type(self.type)
|
|
222
|
+
self.type_name = translate_partition_type(self.type, False)
|
|
222
223
|
self.raw = raw
|
|
223
224
|
|
|
224
225
|
def __repr__(self) -> str:
|
|
225
|
-
type_str = self.type_str
|
|
226
|
-
|
|
227
|
-
if isinstance(self.type, int):
|
|
228
|
-
type = hex(self.type)
|
|
229
|
-
type_key = self.type
|
|
230
|
-
elif isinstance(self.type, bytes):
|
|
231
|
-
type = UUID(bytes_le=self.type)
|
|
232
|
-
type_key = type
|
|
233
|
-
elif isinstance(self.type, str):
|
|
234
|
-
type_str = self.type
|
|
235
|
-
|
|
236
|
-
type_str = type_str or f"{type} ({PARTITION_TYPES.get(type_key, 'Unknown')})"
|
|
237
226
|
return (
|
|
238
227
|
f"<Partition number={self.number} offset=0x{self.offset:x} "
|
|
239
|
-
f"size=0x{self.size:x} type={type_str} name={self.name!r}>"
|
|
228
|
+
f"size=0x{self.size:x} type={self.type_str!r} name={self.name!r}>"
|
|
240
229
|
)
|
|
241
230
|
|
|
242
231
|
def open(self) -> BinaryIO:
|
|
243
232
|
"""Open a stream to the partition."""
|
|
244
233
|
return RangeStream(self.disk.fh, offset=self.offset, size=self.size)
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
def translate_partition_type(type: int | str | UUID, prepend_type: bool = True) -> str:
|
|
237
|
+
"""Translate a partition type to a human-readable format."""
|
|
238
|
+
|
|
239
|
+
if not isinstance(type, str):
|
|
240
|
+
name = PARTITION_TYPES.get(type, "Unknown")
|
|
241
|
+
type = hex(type) if isinstance(type, int) else type
|
|
242
|
+
return f"{type} ({name})" if prepend_type else name
|
|
243
|
+
|
|
244
|
+
return type
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: dissect.volume
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.18.dev1
|
|
4
4
|
Summary: A Dissect module implementing a parser for different disk volume and partition systems, for example LVM2, GPT and MBR
|
|
5
5
|
Author-email: Dissect Team <dissect@fox-it.com>
|
|
6
6
|
License-Expression: AGPL-3.0-or-later
|
|
@@ -21,6 +21,9 @@ def test_apm(apm: BinaryIO) -> None:
|
|
|
21
21
|
assert d.partitions[0].size == 0x7E00
|
|
22
22
|
assert d.partitions[0].type == "Apple_partition_map"
|
|
23
23
|
assert d.partitions[0].name == "Apple"
|
|
24
|
+
assert repr(d.partitions[0]) == (
|
|
25
|
+
"<Partition number=1 offset=0x200 size=0x7e00 type='Apple_partition_map' name='Apple'>"
|
|
26
|
+
)
|
|
24
27
|
|
|
25
28
|
assert d.partitions[1].number == 2
|
|
26
29
|
assert d.partitions[1].offset == 0x8000
|
|
@@ -17,6 +17,7 @@ def test_bsd(bsd: BinaryIO) -> None:
|
|
|
17
17
|
assert vs.partitions[0].size == 0x200
|
|
18
18
|
assert vs.partitions[0].type == 7
|
|
19
19
|
assert vs.partitions[0].guid is None
|
|
20
|
+
assert repr(vs.partitions[0]) == "<Partition number=1 offset=0x800 size=0x200 type='4.2BSD' name=None>"
|
|
20
21
|
assert vs.partitions[0].open().read() == b"\x01" * 512
|
|
21
22
|
|
|
22
23
|
assert vs.partitions[1].number == 2
|
|
@@ -23,15 +23,25 @@ def test_gpt(gpt: BinaryIO) -> None:
|
|
|
23
23
|
assert d.partitions[0].offset == 20480
|
|
24
24
|
assert d.partitions[0].size == 0xC7FFE00
|
|
25
25
|
assert d.partitions[0].type == UUID("c12a7328-f81f-11d2-ba4b-00a0c93ec93b")
|
|
26
|
+
assert d.partitions[0].type_str == "c12a7328-f81f-11d2-ba4b-00a0c93ec93b (EFI System partition)"
|
|
27
|
+
assert d.partitions[0].type_name == "EFI System partition"
|
|
26
28
|
assert d.partitions[0].guid == UUID("27d920bc-e414-45e0-9503-2606de7a1056")
|
|
27
29
|
assert d.partitions[0].name == "EFI System Partition"
|
|
30
|
+
assert repr(d.partitions[0]) == (
|
|
31
|
+
"<Partition number=1 offset=0x5000 size=0xc7ffe00 type='c12a7328-f81f-11d2-ba4b-00a0c93ec93b (EFI System partition)' name='EFI System Partition'>" # noqa: E501
|
|
32
|
+
)
|
|
28
33
|
|
|
29
34
|
assert d.partitions[1].number == 2
|
|
30
35
|
assert d.partitions[1].offset == 0xC900000
|
|
31
36
|
assert d.partitions[1].size == 0x7465FFE00
|
|
32
37
|
assert d.partitions[1].type == UUID("ebd0a0a2-b9e5-4433-87c0-68b6b72699c7")
|
|
38
|
+
assert d.partitions[1].type_str == "ebd0a0a2-b9e5-4433-87c0-68b6b72699c7 (Windows Basic data partition)"
|
|
39
|
+
assert d.partitions[1].type_name == "Windows Basic data partition"
|
|
33
40
|
assert d.partitions[1].guid == UUID("a14cecf3-b364-4d6d-a540-e245e6df9d11")
|
|
34
41
|
assert d.partitions[1].name == ""
|
|
42
|
+
assert repr(d.partitions[1]) == (
|
|
43
|
+
"<Partition number=2 offset=0xc900000 size=0x7465ffe00 type='ebd0a0a2-b9e5-4433-87c0-68b6b72699c7 (Windows Basic data partition)' name=''>" # noqa: E501
|
|
44
|
+
)
|
|
35
45
|
|
|
36
46
|
|
|
37
47
|
def test_gpt_invalid(gpt: BinaryIO) -> None:
|
|
@@ -54,6 +64,7 @@ def test_hybrid_gpt(gpt_hybrid: BinaryIO) -> None:
|
|
|
54
64
|
assert d.partitions[0].type == 0x83
|
|
55
65
|
assert d.partitions[0].guid is None
|
|
56
66
|
assert d.partitions[0].name is None
|
|
67
|
+
assert repr(d.partitions[0]) == "<Partition number=1 offset=0x100000 size=0x80200 type='0x83 (Linux)' name=None>"
|
|
57
68
|
|
|
58
69
|
assert d.partitions[1].number == 2
|
|
59
70
|
assert d.partitions[1].offset == 0x180200
|
|
@@ -61,6 +72,7 @@ def test_hybrid_gpt(gpt_hybrid: BinaryIO) -> None:
|
|
|
61
72
|
assert d.partitions[1].type == 0x83
|
|
62
73
|
assert d.partitions[1].guid is None
|
|
63
74
|
assert d.partitions[1].name is None
|
|
75
|
+
assert repr(d.partitions[1]) == "<Partition number=2 offset=0x180200 size=0x7bc00 type='0x83 (Linux)' name=None>"
|
|
64
76
|
|
|
65
77
|
assert d.partitions[2].number == 1
|
|
66
78
|
assert d.partitions[2].offset == 0x100000
|
|
@@ -68,6 +80,9 @@ def test_hybrid_gpt(gpt_hybrid: BinaryIO) -> None:
|
|
|
68
80
|
assert d.partitions[2].type == UUID("0fc63daf-8483-4772-8e79-3d69d8477de4")
|
|
69
81
|
assert d.partitions[2].guid == UUID("44eea528-8489-4bbc-a480-56bd208cd233")
|
|
70
82
|
assert d.partitions[2].name == "Linux filesystem"
|
|
83
|
+
assert repr(d.partitions[2]) == (
|
|
84
|
+
"<Partition number=1 offset=0x100000 size=0x80000 type='0fc63daf-8483-4772-8e79-3d69d8477de4 (Linux filesystem data)' name='Linux filesystem'>" # noqa: E501
|
|
85
|
+
)
|
|
71
86
|
|
|
72
87
|
assert d.partitions[3].number == 2
|
|
73
88
|
assert d.partitions[3].offset == 0x4400
|
|
@@ -151,6 +166,9 @@ def test_gpt_esxi(gpt_esxi: BinaryIO) -> None:
|
|
|
151
166
|
assert d.partitions[3].type == UUID("4eb2ea39-7855-4790-a79e-fae495e21f8d")
|
|
152
167
|
assert d.partitions[3].guid == UUID("fc7f0906-62a5-47b2-8f40-98d9427fefe0")
|
|
153
168
|
assert d.partitions[3].name == "OSDATA"
|
|
169
|
+
assert repr(d.partitions[3]) == (
|
|
170
|
+
"<Partition number=7 offset=0x206600000 size=0x1df99ffe00 type='4eb2ea39-7855-4790-a79e-fae495e21f8d (Unknown)' name='OSDATA'>" # noqa: E501
|
|
171
|
+
)
|
|
154
172
|
|
|
155
173
|
assert d.partitions[4].number == 8
|
|
156
174
|
assert d.partitions[4].offset == 0x2000100000
|
|
@@ -20,6 +20,7 @@ def test_mbr(mbr: BinaryIO) -> None:
|
|
|
20
20
|
assert d.partitions[0].offset == 0x100000
|
|
21
21
|
assert d.partitions[0].size == 0x1F400000
|
|
22
22
|
assert d.partitions[0].type == 0x7
|
|
23
|
+
assert repr(d.partitions[0]) == "<Partition number=1 offset=0x100000 size=0x1f400000 type='0x7 (NTFS)' name=None>"
|
|
23
24
|
|
|
24
25
|
assert d.partitions[1].number == 2
|
|
25
26
|
assert d.partitions[1].offset == 0x1F500000
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect/volume/disk/schemes/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/dissect.volume.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid0-raid1-1.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/ddf/ddf-raid0-raid1-2.bin.gz
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/dm/dm-thin-empty-data.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/dm/dm-thin-empty-metadata.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/dm/dm-thin-metadata.bin.gz
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-concat_diska.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-concat_diskb.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-mirror_diska.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-mirror_diskb.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-raid5_diska.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-raid5_diskb.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-raid5_diskc.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-raid5_diskd.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-striped_diska.bin.gz
RENAMED
|
File without changes
|
{dissect_volume-3.17.dev3 → dissect_volume-3.18.dev1}/tests/_data/vinum/vinum-striped_diskb.bin.gz
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|