EvilZone
Programming and Scripting => Scripting Languages => : daxda January 23, 2014, 08:44:41 PM
-
Had this project planned for some time now, today I've written it and here it is.
It's a stream grabbing script which attempts to extract direct download links from websites that request a movie file.
I was very pumped to try out another new lib, it's called "scapy", read more about it here (http://www.secdev.org/projects/scapy/) if you didn't heard about it yet and/or are interested.
In short how the script works - it spawns a thread which sniffs your network packets, the main thread pops the gathered packets from the list(which gets refilled in the sniffer thread) and filters them for URLs ending with a movie file extension.
When the filtering of an URL occurs it gets printed to stdout.
The list of dependencies:
- Scapy (http://www.secdev.org/projects/scapy/)
To be able to run this script you must be root!
[gist]Daxda/8585445[/gist]
-
That's awesome brah! have a cookie. It only runs on Linux?
-
Guess am gonna be saved the pain of always running wireshark to grab the download URL. This is amazing dude.
It should be running on Linux just fine and if i remember @daxda programs from Ubuntu.
+1
-
Cool , I did something similar in the past for watching the news(ripping stream).
Keep 'm coming.
-
Thanks for your positive feedback guys, it's appreciated very much!
kenjoe41 is right, I am on ubuntu, the usage of the root check is, afaik for linux only.
I'm not quite sure if it does work on windows when removing the check, it's worth a try.
-
Is using list for accessing the packets thread safe? Your thread and the main process access self._packets without locks (as far as I know) so there maybe a problem.
I suggest using queue instead which has inbuilt blocking mechanism.
-
This is a great idea,
can't get it to work at all on linux, tested with chrome, chromium, firefox
tested all the extentions listed on line 27, with nothing appearing at all.
My system has ipv6 disabled.
Anyone get this to work?
-
This is a great idea,
can't get it to work at all on linux, tested with chrome, chromium, firefox
tested all the extentions listed on line 27, with nothing appearing at all.
My system has ipv6 disabled.
Anyone get this to work?
Glad to take a look at it but you need to give us something to work with.
Output perhaps ?
First thought that comes to mind is that you have not installed prop. codec's.
-
Glad to take a look at it but you need to give us something to work with.
Output perhaps ?
First thought that comes to mind is that you have not installed prop. codec's.
Ok thanks, well i'm on kali 1.06 64-bit.
The only modification i made to the script was to add #!/usr/bin/python to the top of the script so i can run it without typing python.
The output of the script is:
WARNING: No route found for IPv6 destination :: (no default route?)
And thats it. I have scapy installed and when i start scapy from the command line i get:
INFO: Can't import python gnuplot wrapper . Won't be able to plot.
INFO: No IPv6 support in kernel
WARNING: No route found for IPv6 destination :: (no default route?)
Welcome to Scapy (2.2.0)
I didn't know we needed to install anything but scapy as that is what is in the dependency list.
Cheers for any help I usually use FlashGot extension to do this but I like the idea of using scapy.
-
Ok thanks, well i'm on kali 1.06 64-bit.
The only modification i made to the script was to add #!/usr/bin/python to the top of the script so i can run it without typing python.
The output of the script is:
WARNING: No route found for IPv6 destination :: (no default route?)
And thats it. I have scapy installed and when i start scapy from the command line i get:
INFO: Can't import python gnuplot wrapper . Won't be able to plot.
INFO: No IPv6 support in kernel
WARNING: No route found for IPv6 destination :: (no default route?)
Welcome to Scapy (2.2.0)
I didn't know we needed to install anything but scapy as that is what is in the dependency list.
Cheers for any help I usually use FlashGot extension to do this but I like the idea of using scapy.
That can be ignored , scapy loves to be verbose about that.
Does not mean it does not work.
Install this shit just to be sure.
https://wiki.debian.org/MultimediaCodecs (https://wiki.debian.org/MultimediaCodecs)
https://packages.debian.org/sid/gnuplot (https://packages.debian.org/sid/gnuplot)
Those probably won't resolve the issues because those are not errors but warnings.
At least we moved those aside.
What is it with 'Kali'.
Please just move to a proper linux distro :)
-
Yeah i know those warnings don't mean shit i installed the package, (libavcodec-extra-53) still no joy.
I'm going to try it on my ubuntu desktop and yes yes i know ubuntu is shit bla bla bla.
-
Yeah i know those warnings don't mean shit i installed the package, (libavcodec-extra-53) still no joy.
I'm going to try it on my ubuntu desktop and yes yes i know ubuntu is shit bla bla bla.
Its just hogged and too preconfigured but still it is a proper distro compared to kali linux.
-
Not working for me personally on ubuntu :(
maybe I just have bad luck..
Same exact output as on Kali.
By the way, why is Kali not a proper linux distro? Just curious.
I thought them moving it over to the debian filesystem was a step in the right direction.
I use Kali because it has alot of the programs I need pre-installed.
-
Not working for me personally on ubuntu :(
maybe I just have bad luck..
Same exact output as on Kali.
By the way, why is Kali not a proper linux distro? Just curious.
I thought them moving it over to the debian filesystem was a step in the right direction.
I use Kali because it has alot of the programs I need pre-installed.
Yeah it is cute they moved to debian.
But for daily use it is not suitable in many ways.
Look , I dont care helping someone but what do you expect me to do , guess?
Post exact output the running program , dont change anything to the source.
-
Um well it's what i said in my last post, exactly the same output as kali.
I don't see that removing the #!/usr/bin/python from the top would make any difference, unless this is written in python3. I did it anyway and it made no difference.
Its not that important thanks for your help anyway.
If daxda has any idea's then that would be great.
Also if anyone has got this to work can you post your OS and if you had to install anything to get it to work.
I will just have to survive another day without this script lmao.
-
Oh this topic is active :P
I really didn't do any fancy shit, the program doesn't output anything though,
except for files it finds. Are you visiting websites and try to stream a movie?
If not U DOIN' IT WRANG.
I code for py2.7.x only so that shouldn't be an issue.
(click dat image)
(http://i.imgur.com/FXVC4HA.jpg?1)
(http://imgur.com/FXVC4HA)
-
Oh this topic is active :P
I really didn't do any fancy shit, the program doesn't output anything though,
except for files it finds. Are you visiting websites and try to stream a movie?
If not U DOIN' IT WRANG.
I code for py2.7.x only so that shouldn't be an issue.
(click dat image)
(http://i.imgur.com/FXVC4HA.jpg?1)
(http://imgur.com/FXVC4HA)
You know, this was going to be my *almost* reply, giving some test cases and such. I have a feeling the "failed" attempts where some iffy sites. If said "test case urls" don't work then maybe report/ But, there is none so far from people claiming it don;t work.
And if it doesn't work for you, please provide the source of the page it didn't work from. And maybe if Daxda <-- only if Daxda doesn't mind a zip of the captured packets of where it did fail from. But then again, you would need to figure out how to save said captured data to even send it in the first place for review.
Learn something damn you! Apparently it works eh as proven? What are you doing diff and why doesn't it work for you is what we need to know. Daxda needs debug info, not that it just doesn't work....
-
thanks for the post. Haven't thought that it's possible to get the stream file via the packets ( tried it with Wireshark and it worked)
Maybe bit off topic but there's a ff addon for doing that:
https://addons.mozilla.org/en-US/firefox/addon/video-downloadhelper/