Image Acquisition & Mount

जानें AWS हैकिंग को शून्य से हीरो तक htARTE (HackTricks AWS Red Team Expert)!

प्राप्ति

DD

#This will generate a raw copy of the disk
dd if=/dev/sdb of=disk.img

डीसीएफएलडी

#Raw copy with hashes along the way (more secur as it checks hashes while it's copying the data)
dcfldd if=<subject device> of=<image file> bs=512 hash=<algorithm> hashwindow=<chunk size> hashlog=<hash file>
dcfldd if=/dev/sdc of=/media/usb/pc.image hash=sha256 hashwindow=1M hashlog=/media/usb/pc.hashes

FTK इमेजर

आप यहाँ से FTK इमेजर डाउनलोड कर सकते हैं

ftkimager /dev/sdb evidence --e01 --case-number 1 --evidence-number 1 --description 'A description' --examiner 'Your name'

EWF

आप ewf tools का उपयोग करके एक डिस्क छवि उत्पन्न कर सकते हैं। ewf tools

ewfacquire /dev/sdb
#Name: evidence
#Case number: 1
#Description: A description for the case
#Evidence number: 1
#Examiner Name: Your name
#Media type: fixed
#Media characteristics: physical
#File format: encase6
#Compression method: deflate
#Compression level: fast

#Then use default values
#It will generate the disk image in the current directory

माउंट

कई प्रकार

Windows में आप फ्री संस्करण का उपयोग कर सकते हैं Arsenal Image Mounter (https://arsenalrecon.com/downloads/) को फोरेंसिक्स इमेज को माउंट करने के लिए।

Raw

#Get file type
file evidence.img
evidence.img: Linux rev 1.0 ext4 filesystem data, UUID=1031571c-f398-4bfb-a414-b82b280cf299 (extents) (64bit) (large files) (huge files)

#Mount it
mount evidence.img /mnt

EWF

#Get file type
file evidence.E01
evidence.E01: EWF/Expert Witness/EnCase image file format

#Transform to raw
mkdir output
ewfmount evidence.E01 output/
file output/ewf1
output/ewf1: Linux rev 1.0 ext4 filesystem data, UUID=05acca66-d042-4ab2-9e9c-be813be09b24 (needs journal recovery) (extents) (64bit) (large files) (huge files)

#Mount
mount output/ewf1 -o ro,norecovery /mnt

आर्सेनल इमेज माउंटर

यह एक Windows एप्लिकेशन है जो वॉल्यूम को माउंट करने के लिए है। आप इसे यहाँ से डाउनलोड कर सकते हैं https://arsenalrecon.com/downloads/

त्रुटियाँ

  • /dev/loop0 को केवल पढ़ने के लिए माउंट नहीं किया जा सकता इस मामले में आपको फ्लैग -o ro,norecovery का उपयोग करना होगा।

  • गलत एफएस प्रकार, बुरा विकल्प, /dev/loop0 पर बुरा सुपरब्लॉक, कोडपेज या हेल्पर प्रोग्राम गायब है, या अन्य त्रुटि। इस मामले में माउंट विफल हुआ क्योंकि फाइलसिस्टम का ऑफसेट डिस्क इमेज के ऑफसेट से भिन्न है। आपको सेक्टर साइज और स्टार्ट सेक्टर खोजने की आवश्यकता है:

fdisk -l disk.img
Disk disk.img: 102 MiB, 106954648 bytes, 208896 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x00495395

Device        Boot Start    End Sectors  Size Id Type
disk.img1       2048 208895  206848  101M  1 FAT12

नोट करें कि सेक्टर का आकार 512 है और प्रारंभ 2048 है। फिर छवि को इस तरह माउंट करें:

mount disk.img /mnt -o ro,offset=$((2048*512))
जानें AWS हैकिंग को शून्य से हीरो तक htARTE (HackTricks AWS Red Team Expert)!

Last updated