Page 9 of 26 FirstFirst ... 789101119 ... LastLast
Results 121 to 135 of 389

Thread: Overview of Hacking an S3

  1. #121
    Join Date
    Oct 2011
    Posts
    75
    got bootpage to work finally, Now the script is not detecting my tivo drive. I have the drive plugged into a sata port on my ubuntu computer, anythoughts? I know sdb is the tivo drive but it is not detected as such.


    Code:
    jon@server:/hack$ sudo bash ./hack_tivo
    /dev/sda
    /dev/sdb
    Valid TiVo Drive not found. Exiting.
    jon@server:/hack$ /hack/bootpage -p /dev/sdb
    Error opening device /dev/sdb!
    jon@server:/hack$ /hack/bootpage -p /dev/hdb
    Error opening device /dev/hdb!
    Last edited by sanjonny; 12-03-2011 at 01:36 AM.

  2. #122
    Join Date
    Oct 2011
    Posts
    75
    okay, looks like something is wrong in the tivopart section now. I was able to change permissions in the tivopart area to make tivopart.x86 work, but do not know the correct command that it is trying to run. I have my directory structure as such that tivopart is a directory in the root of hack. see below

    Code:
    jon@server:/hack$ ls
    bootpage    bootpage.tgz  Makefile                   tivohacks64.tar
    bootpage.c  hacks.fil     null-linuxrc.img.gz        tivopart
    bootpage.h  hack_tivo     replace_initrd.x86.tar.gz
    bootpage.o  hack_tivoapp  tivohacks32.tar
    jon@server:/hack$ cd tivpart
    bash: cd: tivpart: No such file or directory
    jon@server:/hack$ cd tivopart
    jon@server:/hack/tivopart$ ls
    bin  README.tivopart  src
    jon@server:/hack/tivopart$ cd bin
    jon@server:/hack/tivopart/bin$ ls
    getkey.mips  lba48chk.mips  pdisk.mips  tivopart.mips
    getkey.ppc   lba48chk.ppc   pdisk.ppc   tivopart.x86
    getkey.x86   lba48chk.x86   pdisk.x86
    jon@server:/hack/tivopart/bin$
    I can get tivopart.x68 to run but don't know what it should be doing. Feeling like i am very close now.

    Code:
    jon@server:/hack/tivopart/bin$ /hack/tivopart/bin/tivopart.x86
    usage: /hack/tivopart/bin/tivopart.x86 [ options ] <command> <arguments>
    
    options:
    	-h                       print this help message
    	-f                       ignore errors and FORCE the operation
    	-s <nnn>                 use nnn megs of swap (default 128)
    	-v                       verbose output
    
    commands:
    	d[ump] <drive>           dump the partition table to the screen
    	c[onsolidate] <drive>    rearrange hdX4..hdX8 to produce a bigger hdX14/hdX16
    	l[astpart] <drive>       return the number of the last used partition
    	r[evalidate] <drive>     update the kernel's in-memory partition map
    	t[test] <drive> <part#>  test to see if the kernel's cache of
    	                         partition part#'s offset is consistent with
    	                         the disklabel
    
    WARNING! This program rewrites your partition table! If you do not know what
    you are doing you will probably lose data! This program comes with NO WARRANTY
    so if you screw up your drive it is your OWN DAMN FAULT!!
    
    This program should NOT be used while the drive is in use or while any
    partition on the drive is mounted.
    jon@server:/hack/tivopart/bin$
    But unlike the script, I cannot get tivopart by itself to run, perhaps that is the issue.

    Code:
    jon@server:/hack$ tivopart
    tivopart: command not found
    jon@server:/hack$ /hack/tivopart
    bash: /hack/tivopart: Is a directory
    jon@server:/hack$
    Last edited by sanjonny; 12-03-2011 at 01:37 AM.

  3. #123
    Join Date
    Oct 2011
    Posts
    75
    okay booted with mfslive and was able to get bootpage to work got the hda7 file as the result to the prior command (I think it was bootpage -p /dev/hdb which returned the hd7

    but then tried
    Code:
    jon@server:~/hack/tivopart$ /hack/tivopart/bin/tivopart.x86 r /dev/hdb
    Segmentation fault
    on my ubuntu and got the segmentation fault. Probably still a problem with whatever I am supposed to do with tivopart.zip from the link. Please advise
    Last edited by sanjonny; 12-03-2011 at 01:38 AM.

  4. #124
    Join Date
    May 2007
    Posts
    456
    Two things I noticed, you don't need tivopart if using a boot CD like mfslive since their kernels are already optimized for tivo partitions.

    Also, this command doesn't appear to be pointing to the tivopart file

    you need to unzip tivopart.zip which you must have done if you have tivopart.x86. Try running chmod 755 tivopart.x86 on that file before you run it again. It may not be executable.

  5. #125
    Join Date
    Dec 2004
    Posts
    831
    Quote Originally Posted by sanjonny View Post
    got everything ready to go with right permissions and such, but cannot make bootpage work see errors

    make
    gcc -O3 -c -o bootpage.o bootpage.c
    You don't need to compile bootpage. The already-compiled binary included in alldeadhomiez' .zip file should run just fine. Just move it to /hack.

    Quote Originally Posted by sanjonny View Post
    and while I am at it, do i have to build tivopart and if so how, or is that a directory in the list of files you have listed above. I don't know how to tell.
    No, the compiled tivopart.x86 binary in the bin/ directory of the tivopart .zip file will also run just fine. Just move it to /hack and rename it as tivopart, instead of tivopart.x86.

    In a long listing (`ls -l`), a directory has permissions that start with "d". In the following listing

    Code:
    RAID-Server:/usr/share/pyhme# ll
    total 48296
    drwxr-xr-x   3 root root    4096 Sep 17 05:06 .
    drwxr-xr-x 382 root root   12288 Nov 23 19:44 ..
    -rw-r--r--   1 root root 7969189 Sep  9 19:16 BaseHTTPServer
    -rwxr-xr-x   1 root root      97 Sep  4 09:35 BuildCache
    -rw-r--r--   1 root root     671 Sep 14 23:10 config.ini
    -rw-r--r--   1 root root 8274689 Sep  9 19:15 sys
    -rw-r--r--   1 root root    6186 Sep  9 19:15 time
    -rw-r--r--   1 root root 7969181 Sep  9 19:15 urllib
    drwx------   3 root root    4096 Nov 23 19:07 vidmgr
    -rwxr-xr-x   1 root root   55709 Feb 28  2010 Zeroconf.py
    -rw-r--r--   1 root root   53526 Sep 14 23:11 Zeroconf.pyc
    The first, second, and ninth listings ( ".", "..", and "vidmgr" ) are directories.
    Last edited by lrhorer; 11-30-2011 at 04:41 AM.
    Having trouble with TyTool? Try TyTool Documentation
    Need to hack an S3 / THD? Try S3 Hacking Script

  6. #126
    Join Date
    Dec 2004
    Posts
    831
    Quote Originally Posted by sanjonny View Post
    got bootpage to work finally, Now the script is not detecting my tivo drive. I have the drive plugged into a sata port on my ubuntu computer, anythoughts? I know sdb is the tivo drive but it is not detected as such.


    jon@server:/hack$ sudo bash ./hack_tivo
    /dev/sda
    /dev/sdb
    Valid TiVo Drive not found. Exiting.
    jon@server:/hack$ /hack/bootpage -p /dev/sdb
    Error opening device /dev/sdb!
    jon@server:/hack$ /hack/bootpage -p /dev/hdb
    Error opening device /dev/hdb!
    That means that neither /dev/sda nor /dev/sdb (nor /dev/hdb) is recognized as a TiVo drive. How do you "know" that /dev/sdb is the TiVo drive? OTOH, it may be failing because tivopart has not been successfully run on the TiVo drive.

    The call to bash is superfluous. The interpreter is specified on the first line of the script. Sudo should not be required, either, as long as all the binaries have a permission of 555 and the scripts have a permission of 755. Finally, if the script is called as an argument to bash, then the ./ is superfluous. Running the script straight from the CL does require the ./, however, or else a fully qualified path name (/hack/hack_tivo), unless /hack is specified in the $PATH variable.
    Last edited by lrhorer; 11-30-2011 at 03:28 AM.
    Having trouble with TyTool? Try TyTool Documentation
    Need to hack an S3 / THD? Try S3 Hacking Script

  7. #127
    Join Date
    Dec 2004
    Posts
    831
    Quote Originally Posted by sanjonny View Post
    okay, looks like something is wrong in the tivopart section now. I was able to change permissions in the tivopart area to make tivopart.x86 work, but do not know the correct command that it is trying to run. I have my directory structure as such that tivopart is a directory in the root of hack. see below

    jon@server:/hack$ ls
    bootpage bootpage.tgz Makefile tivohacks64.tar
    bootpage.c hacks.fil null-linuxrc.img.gz tivopart
    bootpage.h hack_tivo replace_initrd.x86.tar.gz
    bootpage.o hack_tivoapp tivohacks32.tar
    jon@server:/hack$ cd tivpart
    bash: cd: tivpart: No such file or directory
    jon@server:/hack$ cd tivopart
    jon@server:/hack/tivopart$ ls
    You cannot have both a directory and a binary file named tivopart in the same directory (/hack). You either need to rename the directory or else change the script to point to a different name. If you choose, you can leave the name as tivopart.x86, and then change the name in the script to tivopart.x86, or you can run `tivopart.x86 r` outside the script (once it is successfully run once, the script no longer uses it - see lines 13 - 17 in the script), or change the name of the directory to something other than tivopart. Once you have moved tivopart.x86 to /hack, you can delete the tivopart directory and rename `tivopart.x86` to `tivopart`, if you like:

    Code:
    mv /hack/tivopart/bin/tivopart.x86 /hack/
    rm -r /hack/tivopart
    mv /hack/tivopart.x86 /hack/tivopart
    Quote Originally Posted by sanjonny View Post
    I can get tivopart.x68 to run but don't know what it should be doing. Feeling like i am very close now.

    jon@server:/hack/tivopart/bin$ /hack/tivopart/bin/tivopart.x86
    There is nothing terribly wrong with issuing the fully qualified pathname, but since you are in the directory already, it isn't necessary. Running ./tivopart.x86 will work fine. Fully qualified pathnames are best practice in a script, but are really just tiresome at the CL, if you are already in the directory.

    Quote Originally Posted by sanjonny View Post
    usage: /hack/tivopart/bin/tivopart.x86 [ options ] <command> <arguments>

    options:
    -h print this help message
    -f ignore errors and FORCE the operation
    -s <nnn> use nnn megs of swap (default 128)
    -v verbose output

    commands:
    d[ump] <drive> dump the partition table to the screen
    c[onsolidate] <drive> rearrange hdX4..hdX8 to produce a bigger hdX14/hdX16
    l[astpart] <drive> return the number of the last used partition
    r[evalidate] <drive> update the kernel's in-memory partition map
    t[test] <drive> <part#> test to see if the kernel's cache of
    partition part#'s offset is consistent with
    the disklabel
    Running `tivopart r <drive>` will make the partitions of a TiVo drive visible to the OS. Once this is accomplished, copying the modified kernel to its proper partition(s) can be accomplished using dd or the kernel can be neutered by using replaceinitrd. The latter method is used by the script. It also allows the ext2 (or whatever) partitions to be mounted by the OS, and ordinary files can be copied or edited on those partitions. It may also be required for bootpage to work. I did not recall this to be the case, but it may be so.

    Quote Originally Posted by sanjonny View Post
    But unlike the script, I cannot get tivopart by itself to run, perhaps that is the issue.

    jon@server:/hack$ tivopart
    tivopart: command not found
    jon@server:/hack$ /hack/tivopart
    bash: /hack/tivopart: Is a directory
    jon@server:/hack$
    Tivopart is not running in the script, because there is no binary named tivopart on your system.
    Last edited by lrhorer; 11-30-2011 at 03:44 AM.
    Having trouble with TyTool? Try TyTool Documentation
    Need to hack an S3 / THD? Try S3 Hacking Script

  8. #128
    Join Date
    Dec 2004
    Posts
    831
    Quote Originally Posted by sanjonny View Post
    okay booted with mfslive and was able to get bootpage to work got the hda7 file as the result to the prior command (I think it was bootpage -p /dev/hdb which returned the hd7

    but then tried

    jon@server:~/hack/tivopart$ /hack/tivopart/bin/tivopart.x86 r /dev/hdb
    Segmentation fault
    on my ubuntu and got the segmentation fault. Probably still a problem with whatever I am supposed to do with tivopart.zip from the link. Please advise
    This is almost surely because there is no /dev/hdb on your Ubuntu system. For any kernel 2.6.26 and above, all SATA and IDE drives are recognized as /dev/sdX. Older kernels (like the one on MFS_Live) map those drives to /dev/hdX. (Actually, it is udev that does the mapping, but the versions of udev linked with 2.6.26 and above map to /dev/sdX.)
    Having trouble with TyTool? Try TyTool Documentation
    Need to hack an S3 / THD? Try S3 Hacking Script

  9. #129
    Join Date
    Oct 2011
    Posts
    75
    Quote Originally Posted by lrhorer View Post
    This is almost surely because there is no /dev/hdb on your Ubuntu system. For any kernel 2.6.26 and above, all SATA and IDE drives are recognized as /dev/sdX. Older kernels (like the one on MFS_Live) map those drives to /dev/hdX. (Actually, it is udev that does the mapping, but the versions of udev linked with 2.6.26 and above map to /dev/sdX.)
    hoping to give this a try again later today. near the end of yesterday, i started getting sick to my stomach literally (because of food poisoning, not the script) and as a result i was not able to think thru as much or get the commands correct it looks like. for anyone wondering i inferred that the mfslive disk would read the tivo drive and therefore i could check the commands and whatever so that is why i boooted to mfslive, i going forward want to have the script working so that nexttime i do this it is as quick as everyone else says. it now seems kinda obvious that i had the wrong drive and such, but shortly after those posts, i was puking my brains out and similarly evacuating the other end, i still am just on gatorade and trying to keep crackers down and maybe some chicken soup later on.

    if you could, scroll back and check my directory for contents. assuming i do as lrhorer said and just rename tivopart.x86 to tivopart and change the tivopart directory name and run the proper tivopart -r /dev/sdb command, am i okay with the images and such in the directory. this is only for a tivohd and hacks.fil is an exact copy currently of the sample. i think after i run the tivopart command, i can then run the script or maybe i dont need to run tivopart once i have it correct in name and location as the script will run it anyway? thanks in advance for you help and comments again. if i do manage to get out of bed later today, i hopefully can get this running.

  10. #130
    Join Date
    May 2007
    Posts
    456
    Quote Originally Posted by sanjonny View Post
    if you could, scroll back and check my directory for contents. assuming i do as lrhorer said and just rename tivopart.x86 to tivopart and change the tivopart directory name and run the proper tivopart -r /dev/sdb command, am i okay with the images and such in the directory. this is only for a tivohd and hacks.fil is an exact copy currently of the sample. i think after i run the tivopart command, i can then run the script or maybe i dont need to run tivopart once i have it correct in name and location as the script will run it anyway? thanks in advance for you help and comments again. if i do manage to get out of bed later today, i hopefully can get this running.
    Yes, that is what I did.

    Once you boot linux with the drive installed pull up a terminal. Get to the root directory so you have full control. On my debian machine I type "su" and it responds asking me for the root user/password.

    Once I am there I type cd / to make sure I'm in the root directory
    then type fidsk -l and this should give you a list of all your drives. You will also be able to see the file system they're showing for your drive. If like mine yours says floppy then you need to update that line in the script.

    ls -l $dspec | grep -q floppy

    next, enter the directory where the hacks are "cd /hacks" and do a chmod 755 hack.sh to make the script executable. You may have to type chmod 755 /hack/hack.sh

    the execute the script by typing ./hack.sh or /hack/hack.sh and sit back and wait for your drive to be hacked.

    PS... Instead of renaming that directory just move the file directly into the hack folder and get rid of that directory. It isn't needed.

  11. #131
    Join Date
    Oct 2011
    Posts
    75
    Thanks. Please look at post 122, does it look like other than tivopart, which I will fix, is everything else in the right form.for this to work? Does the initd ... and the other gzipped files need to.be unzipped or are they ok. On a he box, do I need both hacks 64 and 32 or just 64. One other question for my basic understanding. If I download the files in firefox, the archive manager wants to take them to full directory instead of just to tar stage. Since I want freshcopies of everything, how do I unzip to tar and not further if needed. I still am not at full mental capacity so trying to think of everything in advance now.

  12. #132
    Join Date
    May 2007
    Posts
    456
    Quote Originally Posted by sanjonny View Post
    Thanks. Please look at post 122, does it look like other than tivopart, which I will fix, is everything else in the right form.for this to work? Does the initd ... and the other gzipped files need to.be unzipped or are they ok. On a he box, do I need both hacks 64 and 32 or just 64. One other question for my basic understanding. If I download the files in firefox, the archive manager wants to take them to full directory instead of just to tar stage. Since I want freshcopies of everything, how do I unzip to tar and not further if needed. I still am not at full mental capacity so trying to think of everything in advance now.
    Not sure what list you're referring to in that post but if you cruise over to post 30 there are links to all the files you need in addition to the two scripts.

    Yes you need both replace_initrd.x86 and null-linuxrc.img.gz. They are what the scripts use to neuter the kernel.

    The other depends on your Tivo. 64 is for TivoHD and 32 is for S3. You only need one or the other not both.

  13. #133
    Join Date
    Dec 2004
    Posts
    831
    Quote Originally Posted by Soapm View Post
    next, enter the directory where the hacks are "cd /hacks" and do a chmod 755 hack.sh to make the script executable. You may have to type chmod 755 /hack/hack.sh
    That presumes he named the main script "hack.sh".
    Having trouble with TyTool? Try TyTool Documentation
    Need to hack an S3 / THD? Try S3 Hacking Script

  14. #134
    Join Date
    Dec 2004
    Posts
    831
    Quote Originally Posted by sanjonny View Post
    Thanks. Please look at post 122, does it look like other than tivopart, which I will fix, is everything else in the right form.for this to work? Does the initd ... and the other gzipped files need to.be unzipped or are they ok.
    We can't really tell. From the directory containing the hacking files, issue the command

    Code:
    ls -l
    and paste the results back to this thread. As I said, minimally it should look like:

    Code:
    RAID-Server:/hack# ls -l
    total 37908
    drwxr-xr-x  6 root            root        4096 Nov 23 16:37 .
    drwxrwxrwx  7 Leslie A Rhorer users       4096 Jul 27 20:02 ..
    drwxr-xr-x  3 root            root         133 Jul 20  2008 Archives
    -rwxr-xr-x  1 root            root      415344 May  6  2008 bootpage
    -rw-r--r--  1 root            root         199 Oct 23  2010 hacks.fil
    -rwxr-xr-x  1 root            root        2019 Oct 23  2010 hack_tivo
    -rwxr-xr-x  1 root            root        1600 Oct 24  2010 hack_tivoapp
    -rw-rw-r--  1             500     501      432 Feb  2  2007 null-linuxrc.img.gz
    -rwxrwxr-x  1             500     501     6573 Feb  2  2007 replace_initrd.x86
    drwxr-xr-x  2 root            root          67 Oct 24  2010 Saved_Apps
    drwxr-xr-x  2 root            root        4096 Oct 23  2010 Saved_Kernels
    -rw-r--r--  1 root            root     2820678 Oct  3 17:58 tivohacks64.tar.gz
    -r-xr-xr-x  1 root            root      472032 Jul 20  2008 tivopart
    Last edited by lrhorer; 12-01-2011 at 07:39 AM.
    Having trouble with TyTool? Try TyTool Documentation
    Need to hack an S3 / THD? Try S3 Hacking Script

  15. #135
    Join Date
    Oct 2011
    Posts
    75
    Quote Originally Posted by lrhorer View Post
    We can't really tell. From the directory containing the hacking files, issue the command

    Code:
    ls -l
    and paste the results back to this thread. As I said, minimally it should look like:

    Code:
    RAID-Server:/hack# ls -l
    total 37908
    drwxr-xr-x  6 root            root        4096 Nov 23 16:37 .
    drwxrwxrwx  7 Leslie A Rhorer users       4096 Jul 27 20:02 ..
    drwxr-xr-x  3 root            root         133 Jul 20  2008 Archives
    -rwxr-xr-x  1 root            root      415344 May  6  2008 bootpage
    -rw-r--r--  1 root            root         199 Oct 23  2010 hacks.fil
    -rwxr-xr-x  1 root            root        2019 Oct 23  2010 hack_tivo
    -rwxr-xr-x  1 root            root        1600 Oct 24  2010 hack_tivoapp
    -rw-rw-r--  1             500     501      432 Feb  2  2007 null-linuxrc.img.gz
    -rwxrwxr-x  1             500     501     6573 Feb  2  2007 replace_initrd.x86
    drwxr-xr-x  2 root            root          67 Oct 24  2010 Saved_Apps
    drwxr-xr-x  2 root            root        4096 Oct 23  2010 Saved_Kernels
    -rw-r--r--  1 root            root     2820678 Oct  3 17:58 tivohacks64.tar.gz
    -r-xr-xr-x  1 root            root      472032 Jul 20  2008 tivopart
    looks like i am close, wondering if I can keep the replace_initrd.x86 as the gzip since it has busybox and other stuff I think I would eventually use or should I just used the extracted version.Hopefully someone can respond soon as I am about to pull the drive and go for it. my directory listing is below, All the files are in green which hopefully means the permissions are correct. Other and tivopartdir are just places I stored the extra files for now.
    Code:
    ^Cjon@server:/hack$ ls -l
    total 9192
    -rwxrwxr-x 1 jon  jon   593260 2011-11-29 14:44 bootpage
    -rwxr-xr-x 1 root root     329 2011-11-29 13:39 hacks.fil
    -rwxr-xr-x 1 root root    3214 2011-11-29 14:15 hack_tivo
    -rwxr-xr-x 1 root root    2277 2011-11-29 14:17 hack_tivoapp
    -rwxr-xr-x 1 root root     432 2011-11-15 14:58 null-linuxrc.img.gz
    drwxr-xr-x 2 root root    4096 2011-12-01 17:39 other
    -rwxrwxr-x 1  500  501    6573 2007-02-02 12:46 replace_initrd.x86
    -rwxr-xr-x 1 root root   12128 2011-11-15 14:45 replace_initrd.x86.tar.gz
    -r-xr-xr-x 1 jon  jon  8294400 2011-11-29 14:53 tivohacks64.tar
    -r-xr-xr-x 1 root root  475996 2011-11-15 14:42 tivopart
    drwxrwxrwx 4 root root    4096 2011-11-15 14:42 tivopartdir
    So can I remove replace_initrd.x86 and the script will use the gzipped version or should I remove the gzipped version and just use the .x86 (extracted) version. I do not have the saved apps or saved kernels folders but I believe the script generates them itself.

    On the permissions front, does it matter that some are root and some are jon as the owner or will sudo fix that anyway? I used either chmod 755 or 555 on the applicable files, is it a huge issue if I used 555 where 755 was supposed to be used? I cannot remember which numbers mean what.

    Assuming the script doesnt work because tivopart has not been run, (I will try the script first), but just in case it fails, then I need to run tivopart -r /dev/sdb to make the script work? (assuming I check and dev/sdb is the proper drive when I reboot with the drive in place. While i am on that, what is the best command to use to check to make sure I have the right drive letter? I am sure I know but double checking is always good.

    Something else interesting, and again a doublecheck. When I tried to just run tivopart to get the commands, it would not run unless I used /hack/tivopart. I thought if I was in the directory it would but just plain tivopart didn't work? Not super important question, just curious, the other questions are much more important.

    Thanks, and yes, I am keeping food down now. finally. Two days of hell

    One last thought, as I mentioned, this is on a two drive system (2nd being esata wd) any issues with doing the hack and still getting recordings and such? I think it is okay, but triplechecking to make sure I am not forgetting anything.
    Last edited by sanjonny; 12-03-2011 at 01:45 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •