/usr/share/perl5/FlashVideo/Site/Xhamster.pm is in get-flash-videos 1.25~git2012.06.27-2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | # Part of get-flash-videos. See get_flash_videos for copyright.
package FlashVideo::Site::Xhamster;
use strict;
use FlashVideo::Utils;
sub find_video {
my ($self, $browser) = @_;
my $server;
if ($browser->content =~ m{'srv': '(http://[^'"]+)'}) {
$server = $1;
}
else {
die "Couldn't determine xhamster server";
}
my $video_file;
if ($browser->content =~ m{'file': '([^'"]+\.flv)'}) {
$video_file = $1;
}
else {
die "Couldn't determine xhamster video filename";
}
my $filename = title_to_filename(extract_title($browser));
my $url = sprintf "%s/flv2/%s", $server, $video_file;
# I want to follow redirects now
$browser->allow_redirects;
return $url, $filename;
}
1;
|