[mythtv-users] What NOT to do to your Myth box...

tommy myth-user at tommywatson.com
Thu Jan 13 22:08:09 EST 2005


Maarten wrote:

>On Friday 14 January 2005 02:36, tommy wrote:
>  
>
>>proxy/ssh -l...), basically I want to show the recorded programs page to
>>anyone who clicks on the link a copy of the recorded programs page
>>without requiring a password and without letting them access the actual
>>box. I thought a wget of the page would be a cheap/easy/quick way to do
>>this, boy was I ever wrong...
>>    
>>
>Hum, if you're really persistent about using your wget, I think that can be 
>done if you make sure you just get the _file_ and not all links(!) that it 
>offers.  So in other words, you should NOT have used the -r switch to wget. 
>Don't try to sue me if it fscks it up again, but you might wanna try with 
>just 'wget <file>', definitely without the -r recursive flag. Else: use scp.
>  
>

I took another quick look at it just then, I figure kick it while it's 
down ;-) Before I go on I'd just like to say I like to dabble a little 
in C++, I am definatley not a web, but what they hey I'll have a go... I 
looked at the recorded_programs.php files and saw that the one in the 
themes dir looked to me like it was checking for java script when a 
delete url came in, if it was enabled it would popup a confirm dialog, 
if not it just went ahead and deleted it, fair enough, I think I just 
figured out where all my tv shows went... :-(
Anyway, I hacked up a couple of recorded_programs.safe.php by removing 
the code that delt with deletes. Then a mate of mine, once he had 
stopped laughing, which took quite some time btw, send me some info on 
wget's -R option, the two combined with this script:

#!/bin/bash
cd /var/www/localhost/htdocs
wget -r -R .nuv,.php http://vector/mythtv/recorded_programs.safe.php
wget http://vector/mythtv/recorded_programs.safe.php -O 
vector/mythtv/recorded_programs.php
cat /var/www/localhost/htdocs/cgi-responses/mythtv-recorded_programs.html

give me exactly what I'm looking for, I am now a happy chap though down 
500GB of "quality" tv...

>>As Ivor said, "Hey it's only TV" ;-)
>>    
>>
>
>Hum... "only TV", sure...
>I'd be crying for weeks if it'd happened to me.  Entire seasons Sopranos, Six 
>Feet Under and News Radio gone, not to mention all movies...   ARGH !
>  
>

well, feel free to learn from my dumb*ss mistakes any time you want...

>Come to think of it, a configuration option to disable deleting from within 
>mythweb may be a good idea...  I often showed the webinterface to friends and 
>stuff and I was always afraid some wiseguy might delete a few shows when I'm 
>not looking... you know how it is sometimes, especially if you leave your 
>laptop for an instant to get a new beer or something...  (-:
>  
>

I hear you ;-) which brings me to a rather puzzling thing, actually it's 
rather amusing really, it seems when I wget the files from mythtv to the 
webserver I'm obviously not getting all the php code and there is all 
this stuff about beers displayed.

http://www.tommywatson.com/alog/beers.jpg

made me grin... speaking of beers, it's time for a fresh one, I was 
hoping clicking on "empty beers" would bring me a new one, no joy, I 
guess I have to get it myself...

 Cheers!






More information about the mythtv-users mailing list