rt2yrru / get-flash-videos

Automatically exported from code.google.com/p/get-flash-videos
0 stars 0 forks source link

Error + Request : Wat.tv #304

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
./combined-get_flash_videos
debug "http://www.wat.tv/video/jonathan-quitte-secret-story-4030r_2ey7v_.html"

Error, auth failed

kbuntu , i tried normal & 25 dev

I'm noob

So i tested without your program befor knowing its existence. I got the same 
error of identification :

The better i got that I can start to download but 0 bit are transfered, the 
worst was forbiden access although i'can watch with normal player

With HD option on, the download works,so it would be cool to replace sd by hd, 
(it works + better quality)

Original issue reported on code.google.com by florian....@free.fr on 20 Aug 2011 at 9:57

GoogleCodeExporter commented 8 years ago
Ok please forgive me for my previous post, i read it back and it s ugly :p

So i tried to find a way with mozilla and your script and i think maybe i got a 
solution.
I tested in HD:

for small duration video i' got
I got a direct link (h264) 

for long video I got a html with a rtmpt link.
I can download it with rtmpdump :

rtmpdump -r "rtmpt://wsl3.wat.tv/watstreaming/" -y 
"mp4:2/H264-384x288/63/95/6516395.h264?bu=TF1&login=secret-story" -W 
"http://www.wat.tv/images/v40/PlayerWat.swf" -o Video.mp4

I dont know how to make that with perl so i'm using your script in C# + i 
launch DOS command :)

With perl code : for Low Def:
------------------------------------ 
sub find_video {
  my ($self, $browser) = @_;

  $browser->content =~ /url\s*:\s*["'].*?nIc0K11(\d+)["']/i
    || die "No video ID found";
  my $video_id = $1;

  $browser->get("http://www.wat.tv/interface/contentv3/$video_id");

  my $title = json_unescape(($browser->content =~ /title":"(.*?)",/)[0]);

  my $location = "/web/$video_id";
  my $token = &token($location);

  my $url = "http://www.wat.tv/get".$location.
         "?token=".$token.
         "&context=swf2&getURL=1&version=WIN%2010,3,181,14";

With perl code : for  hd :
------------------------------------ 
sub find_video {
  my ($self, $browser) = @_;

  $browser->content =~ /url\s*:\s*["'].*?nIc0K11(\d+)["']/i
    || die "No video ID found";
  my $video_id = $1;

  $browser->get("http://www.wat.tv/interface/contentv3/$video_id");

  my $title = json_unescape(($browser->content =~ /title":"(.*?)",/)[0]);

  my $location = "/webhd/$video_id";
  my $token = &token($location);

  my $url = "http://www.wat.tv/get".$location.
         "?token=".$token.
         "&context=swf2&getURL=1&version=WIN%2010,3,181,14";
------------------------------------------------------------------
My own C# translation of your work at the same point (working for me):
        public static void GetVideo(String url_in)
        {
            //rtmpdump -r "rtmpt://wsl3.wat.tv/watstreaming/" -y "mp4:2/H264-384x288/63/95/6516395.h264?bu=TF1&login=secret-story" -W "http://www.wat.tv/images/v40/PlayerWat.swf" -o Video.mp4

            //DOWNLOAD :

            String Contenu = GetTexteFiable(url_in, true);
            Contenu = Contenu.Replace("\n", "[LN]");
            Contenu = Contenu.Replace("\r", "[LN]");

            //RECHERCHE :
            Console.WriteLine("Recherche de : VideoID : ");
            MatchCollection matchResults = null;
            matchResults = regex1.Matches(Contenu);
            String VideoID = "";
            if (matchResults.Count > 0)
            {
                for (int i = 0; i <= matchResults.Count - 1; i++)
                {
                    Match match = (Match)matchResults[i];
                    VideoID = match.Groups[1].Value;
                }
            }
            Console.WriteLine("    VideoID vaut \"" + VideoID + "\"");
            Console.WriteLine("Recherche de : Titre : ");
            // my $title = json_unescape(($browser->content =~ /title":"(.*?)",/)[0]);
            matchResults = regex2.Matches(Contenu);
            String Titre = "";
            if (matchResults.Count > 0)
            {
                for (int i = 0; i <= matchResults.Count - 1; i++)
                {
                    Match match = (Match)matchResults[i];
                    Titre = match.Groups[1].Value;
                }
            }

            Console.WriteLine("    Titre vaut \"" + Titre + "\"");

            //LOCATION
            String location = "/webhd/" + VideoID;

            //TOKEN
            String Token = token(location).ToLower();

            String urlfinale = "http://www.wat.tv/get" + location + @"?token=" + Token + "&domain=www.wat.tv&domain2=www.wat.tv&revision=4.1.008&synd=0&helios=1&context=swf2&pub=5&country=FR&sitepage=WAT%2Ftv%2Fcatchup%2Fsecret-story&lieu=wat&playerContext=CONTEXT_WAT&getURL=1&version=WIN 10,3,181,34";
            Console.WriteLine(urlfinale);

        }

I only tested in secret story videos, (for my momy)

Original comment by florian....@free.fr on 21 Aug 2011 at 1:22

GoogleCodeExporter commented 8 years ago
PS : you need to get the real id from the video with the contentV3 response 
(and it can say if hd is available or not)

Original comment by HDTNT...@gmail.com on 25 Aug 2011 at 1:58