VectorLinux
December 20, 2014, 03:17:57 pm *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Visit our home page for VL info. To search the old message board go to http://vectorlinux.com/forum1. The first VL forum is temporarily offline until we can find a host for it. Thanks for your patience.
 
Now powered by KnowledgeDex.
   Home   Help Search Login Register  
Please support VectorLinux!
Pages: [1]
  Print  
Author Topic: [SOLVED] Read RootFS  (Read 375 times)
roarde
Vectorian
****
Posts: 553


move the needle


« on: November 05, 2014, 01:06:25 pm »

Given an on-disk /boot/vmlinuz-3.x.x, is there a way to look at the files in its RootFS, or at least list them?
« Last Edit: November 07, 2014, 06:31:40 pm by roarde » Logged

Robert
VL STD 7.1 RC3.1, icewmvmods
roarde
Vectorian
****
Posts: 553


move the needle


« Reply #1 on: November 07, 2014, 06:39:13 pm »

OK, found a script in kernel source's scripts/ directory that decompresses the kernel itself. It does this by looking for the header of the compressed portion, which is found and identified by a few characters, similar to (same as?) "file magic". Starting at that location, the file is tailed through a pipe to the proper decompression program.

I'm sure that, having that decompressed kernel, one could just follow the same process but look for cpio's unique signature. Only added difficulty would be finding the end; or maybe cpio will still output despite trailing "garbage". Haven't checked. Mainly needed a firm idea that it was possible, and looks like it is.

Haven't actually tried this, but for my purposes it's solved.
Logged

Robert
VL STD 7.1 RC3.1, icewmvmods
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!