How to Capture Adobe Flash Videos on Ubuntu Linux

Part 1 of 3:

Preparing Your Ubuntu Linux System

  1. How to Capture Adobe Flash Videos on Ubuntu Linux Picture 1
    Issue the following commands below in order to prepare your Ubuntu Linux system to capture embedded Adobe flash videos from websites.
    1. Type: sudo -s apt-get update. This will update your repository sources.
    2. Type: sudo -s apt-get install perl. This will install the Perl, programming language, you will need Perl in order to run your FlashVideoCapture.pl script.
    3. Type: sudo -s apt-get install lsof. This will install lsof if it is not already installed.
    4. Type: sudo -s apt-get install firefox. This will install the Mozilla Firefox web browser.
    5. Type: sudo -s apt-get install vlc. This will install the VLC multimedia player in order to playback your captured *.flv videos.
    6. Important Note: You must use the Firefox browser to view your FLV videos because this does not work in Google Chrome.
  2. How to Capture Adobe Flash Videos on Ubuntu Linux Picture 2
    Open up a text editor such as gedit or nano.
      1. Type: gedit FlashVideoCapture.pl
    or
    1. Type: nano FlashVideoCapture.pl
  3. How to Capture Adobe Flash Videos on Ubuntu Linux Picture 3
    Type the following perl script located in the box below and save it as FlashVideoCapture.pl:
    #!/usr/bin/perl[[Image:Capture Adobe Flash Videos on Ubuntu Linux Step 1 Version 5.jpg|center]] #Filename: FlashVideoCapture.pl use strict;[[Image:Capture Adobe Flash Videos on Ubuntu Linux Step 2 Version 5.jpg|center]] ################################################## #Setup the variables[[Image:Capture Adobe Flash Videos on Ubuntu Linux Step 3 Version 5.jpg|center]] ################################################## my $PROGNAME = $0; $PROGNAME =~ s|.*/||; my $LSOF = 'lsof'; my $FIND = 'flash'; # Find flash files my $POST = 'flv'; # Postfix to save to #Where we save files[[Image:Capture Adobe Flash Videos on Ubuntu Linux Step 4 Version 5.jpg|center]] #%f is $FIND[[Image:Capture Adobe Flash Videos on Ubuntu Linux Step 5 Version 5.jpg|center]] #%d is the next available number[[Image:Capture Adobe Flash Videos on Ubuntu Linux Step 6 Version 5.jpg|center]] #%p is .$POST my $DEST = "found%f.%d%p";[[Image:Capture Adobe Flash Videos on Ubuntu Linux Step 7 Version 5.jpg|center]] ################################################## #Usage[[Image:Capture Adobe Flash Videos on Ubuntu Linux Step 8 Version 5.jpg|center]] ################################################## sub fatal { foreach my $msg (@_) { print STDERR "[$PROGNAME] ERROR: $msgn"; } exit(-1); } sub usage { foreach my $msg (@_) { print STDERR "ERROR: $msgn"; } print STDERR <<USAGE; Usage:t$PROGNAME [-d]  Copies deleted flash files currently open in your browser's cache  -d Set debug mode  -find What to search for [default $FIND]  -post Postfix for saving files [default $POST]  -dest Or just specify full destination [default $DEST]  (see the script for meanings of %f, %d, %p) USAGE exit -1; } sub parseArgs { usage("You need to be on a system that uses /proc") unless -d '/proc'; my $opt = { find => $FIND, post => $POST, dest => $DEST, }; while (my $arg=shift(@ARGV)) { if ($arg =~ /^-h$/) { usage(); } if ($arg =~ /^-d$/) { $MAIN::DEBUG=1; next; } if ($arg =~ /^-find$/) { $opt->{find} = shift(@ARGV); next; } if ($arg =~ /^-post$/) { $opt->{post} = shift(@ARGV); next; } if ($arg =~ /^-dest$/) { $opt->{dest} = shift(@ARGV); next; } if ($arg =~ /^-/) { usage("Unknown option: $arg"); } usage("Too many files specified [$arg and $opt->{file}]") if $opt->{file}; } usage("You need to specify a destination with -dest") unless $opt->{dest}; usage("You need to specify something to search for with -find") unless $opt->{find}; $opt; } sub debug { return unless $MAIN::DEBUG; foreach my $msg (@_) { print STDERR "[$PROGNAME] $msgn"; } } ################################################## #Main code[[Image:Capture Adobe Flash Videos on Ubuntu Linux Step 9 Version 5.jpg|center]] ################################################## sub findFiles { my ($opt) = @_; my @found; #'lsof /' (The '/' just does files, no sockets, and is faster) open(LSOF,"$LSOF /|") || usage("Can't run [$LSOF]"); while () { next unless /delete/i; next unless /Q$opt->{find}E/i; next if /.adobe/; # Ignore adobe 'flash' db files chomp;[[Image:Capture Adobe Flash Videos on Ubuntu Linux Step 10 Version 4.jpg|center]] #procname pid user fd usage("Found it, can't parse it [$_]") unless /^S+s+(d+)s+S+s+(d+)/; push(@found, [$1,$2]); } usage("Couldn't find any deleted cached $opt->{find} files") unless @found; @found; } sub procPath { my ($pid,$fd) = @_; my $path = "/proc/$pid"; usage("Couldn't find $path") unless -d $path; $path .= '/fd'; usage("Couldn't find $path") unless -d $path; $path .= "/$fd"; usage("Couldn't read $path") unless -e $path; $path; } sub destPath { my ($opt) = @_; my $p = $opt->{dest}; $p =~ s/%f/Q$opt->{find}E/g; $p =~ s/%p/.Q$opt->{post}E/g; my $num = 0; my $path; do { $path = $p; $num++; $path =~ s/%d/$num/g; } until ! -f $path; $path; } sub main { my $opt = parseArgs(); my @found = findFiles($opt); foreach my $found ( @found ) { my $src = procPath(@$found); my $dest = destPath($opt); print "$src -> $destn"; system("/bin/cp",$src,$dest); } } main(); 
Part 2 of 3:

Configuring a Capture Directory and Enabling the FlashVideoCapture.pl Script

  1. How to Capture Adobe Flash Videos on Ubuntu Linux Picture 4
    Copy the FlashVideoCapture.pl script to your /home/"your_user_name"/Videos directory.
    1. You will either need to change into your Videos directory or create a dedicated directory where you store your multimedia videos.
  2. How to Capture Adobe Flash Videos on Ubuntu Linux Picture 5
    Create a directory. If you don't have a Videos directory on your system, the command below will allow you to create one.
    1. Type:mkdir -p /home/"your_user_name"/ Videos.
      1. This command will create your Videos directory.
    2. Type: cd /home/"your_user_name"/.
      1. Change into your home directory.
    3. Type: cp -r FlashVideoCapture.pl /home/'your_user_directory'/Videos
      1. Copy the FlashCaptureVideo.pl script to your Videos directory.
    4. Type: cd /home/'your_user_name'/Videos.
      1. Once the FlashVideoCapture.pl script is in your Videos directory, you will open up terminal and change into your Videos directory.
    5. Type: chmod +x FlashVideoCapture.pl.
      1. This command will make the FlashvideoCapture.pl perl script executable.
Part 3 of 3:

Capturing Your Flash Video

  1. How to Capture Adobe Flash Videos on Ubuntu Linux Picture 6
    Start up your Firefox web browser and go to a site which has embedded flash videos in it.
  2. How to Capture Adobe Flash Videos on Ubuntu Linux Picture 7
    Allow the Flash video to play/load in the web browser until it is completely loaded into the browsers cache. You can tell the video has completely loaded by the grey bar at the bottom of the Flash video, which will usually indicate the load and completion of the video. Once the grey bar load cycle is complete and 100% of the video has been loaded it's time to capture the video stored in your web browsers cache.
  3. How to Capture Adobe Flash Videos on Ubuntu Linux Picture 8
    Keep your Firefox web browser open with the video completely loaded. Return to your open terminal and run the FlashVideoCapture.pl script by issuing the following command:
    1. Type: cd /home/"your_user_name"/Videos
      1. This will change you into your Videos directory, make sure you are in the Videos directory and you have the FlashVideoCapture.pl script in this directory.
    2. Type: ./FlashVideoCapture.pl
      1. This command will execute the FlashVideoCapture.pl script and capture the *.flv video files to your /home/"your_user_name"/Videos directory.
  4. How to Capture Adobe Flash Videos on Ubuntu Linux Picture 9
    Review the results. If this was done correctly, you will see a statement such as this:
    1. /proc/13509/fd/28 -> foundflash.1.flv
      1. This means the flash video was captured as foundflash1.flv. In order to view the video you can use the VLC mediaplayer to view the captured *.flv file.
  5. How to Capture Adobe Flash Videos on Ubuntu Linux Picture 10
    Play back your captured *.flv video files. Make sure you are in the /home/"your_user_name"/Videos directory before running the following commands.
    1. Type: cd /home/"your_user_name"/Videos
    2. Type: vlc foundflash1.flv.
      1. or
    3. Type: vlc *.flv
      1. This will playback all *.flv video files stored in your /home/"your_user_home"/Videos directory.
  6. How to Capture Adobe Flash Videos on Ubuntu Linux Picture 11
    Rename the foundflash1.flv to anything you like. So that you can view the captured *.flv video over and over again using the VLC media player without loading it from your Firefox web browser.
3.5 ★ | 2 Vote

May be interested

  • Fix Flash errors when watching videos on YouTubeFix Flash errors when watching videos on YouTube
    flash-related errors that youtube uses to play videos can cause problems such as videos showing only blue screens, browser errors ... the following solutions will help you solve this problem.
  • Adobe said goodbye to Flash Media Player by 2020Adobe said goodbye to Flash Media Player by 2020
    in a joint statement with apple, facebook, google, microsoft and mozilla, adobe announced plans to stop supporting adobe flash media player by 2020.
  • Run Linux from USB Flash DriveRun Linux from USB Flash Drive
    do you want to run linux anytime, anywhere? in this article, we will show you what you can do with popular linux distributions like puppy linux, ubuntu, and fedora to be able to launch directly from a usb drive.
  • Instead of killing Flash, we should save it for posterityInstead of killing Flash, we should save it for posterity
    adobe has decided to launch flash player in 2020, but not only has important implications in internet history, flash also contains a lot of content that we probably won't want to leave.
  • Watch YouTube videos on Linux Mint 11 with MinitubeWatch YouTube videos on Linux Mint 11 with Minitube
    in the following article, we will guide and introduce you to a support tool for watching youtube videos on the desktop platform, specifically the linux mint 11 operating system called minitube - essentially 1 chapter with a graphical interface, where the user can enter the search keyword, the system will fully display the return list with information
  • How to use Adobe Flash after it was discontinuedHow to use Adobe Flash after it was discontinued
    adobe flash has officially entered the end-of-life (eol - death) phase starting december 31, 2020.
  • What is Adobe Animate? Overview of Adobe AnimateWhat is Adobe Animate? Overview of Adobe Animate
    what is adobe animate? previously, adobe provided users with adobe flash software to create 2d cartoons and animated animations by drawing characters. however, the fate of adobe flash is not very good, it is not used by many people because the tools are very 'imprisoned' and unreasonable.
  • 8 ways Ubuntu changes and improves Linux8 ways Ubuntu changes and improves Linux
    ubuntu is the most prominent linux distribution in the world. ubuntu and its developer, canonical, have been plagued by a lot of fuss over the years, but the linux world is getting much better thanks to both.
  • How to Install Flash Player on UbuntuHow to Install Flash Player on Ubuntu
    flash is no longer being developed for linux, and the newest versions are only available built-in to chrome. if you use the chromium browser, you can extract the flash plugin from chrome and use it. if you use firefox, you'll need to...
  • Tips and tricks after installing UbuntuTips and tricks after installing Ubuntu
    ubuntu is one of the completely free open source operating systems. this is a distribution (distro) of linux with the second highest amount of traffic after linux mint.