Description: Welcome to our "Python for Hackworkers" primer (with Scapy)!
This Primer is geared towards Hackers, Pentesters, Admins,...
------------
Part1 (INTRO):
In the Python part of video, we jump right into the code and cover your first Python TCP client and server and walk you through each of them, line by line.
The Scapy part of the video will show you basic packet analysis in Scapy with a few helpful "making yourself feel at home in Scapy" tips. You will also walk out of this part with a better understanding of SYN/ACK/FIN packets, and what TCP connections and disconnects look like "on the wire".
We also have a little surprise at the end
The Source files (python 2.6) can be downloaded at: https://github.com/piman/PyPrimer-for-Hackers/
------------
Some key points we want to cover in the whole video series:
*) toolz often lie! code your own networking tools and get the correct feedback!
*) code your own networking environments
*) some network attacks
*) run your toolz on several machines and communicate with them
*) ...and other funny stuff ;)
------------
Please tell us what you like and what you don't like!
If you have ideas on what should be covered in future videos, please let us know!
We strongly disadvise from doing anything malicious! We just want to provide some knowledge for security tests and show developers how to code proper software.
Tags: python , scapy , hacker , hacking , coding , programming , network , lan , rene schallner , patrick schallner , server , client ,
Disclaimer: We are a infosec video aggregator and this video is linked from an external website. The original author may be different from the user re-posting/linking it here. Please do not assume the authors to be same without verifying.
Hi,
nice video,
i would like to give you a littel feedback :)
Say wich version of python youre using ...
give a downloadlink for the sourcefiles :)
Hi and thanks!
We are using PYTHON 2.6 (I think you should be fine with every 2.x version)
We are of course looking for a place to store the source files (but we also thought that people would remember/understand everything better if they have to type every line themselves instead of copy/pasting everything).
Thx for the feedback!
youre welcome :)
pthon 2.6 is compatible with all the 2.x versions - i thought i would be a good advice for not trying this with python 3.x :)
sourcefiles would be great for beginners - because the video isnt HD and its hard to tell if its a "." oder a "," ;)
@storing files: try dropbox :) you can share a public downloadlink .... and its free :)
Thanks Patrick and Rene for dedicating your time to produce this video. Keep 'em coming. I will personally email you to ask you some questions on Python and Malware research.
FILES are available here for now:
http://www.filefactory.com/f/a38040d40dac60f8/
and also here:
http://uploaded.to/file/vt3yzy81
hopefully that's ok!
I will create a dropbox folder for your primers soon... but I don't have so much time now!
btw: thx for the comments!
Very good video, looks interesting and python is my favorite programming language (its easy). I’ll be looking forward to your series. Everything was clearly explained and I understood everything although I have already done basic Sockets in python so I wasn’t a complete new be.
Only got to watch half the video it’s a late night here (I need to get up early tomorrow) and I can’t wait to finish watching this video tomorrow.
Wow, thanks a lot Patrick.
1 hour Python tutorial ..... Awesome :D
Watching it right now, seems pretty interesting and thanks for the source codes.
Hi Patrick,
It shows some proper time and dedication has been put in this work. On top, Python and network is definetely a win-win combination, so 2x thanks. I do agree with including the materials, for the same reasons as mentioned above. It just increases the attention span a little bit more.
Can't wait for the second episode
Good job guys!
very good and clear code-examples :)
Keep going!
Very nice vid, but for the next time could u do a more advanced stuff, i've to thank you for your time to share that's very nice from you. Guten arbeite ciuzz
thanks for all the comments :)!
we are really happy about the feedback!
@hazz:
we don't want to frighten people who are fairly new to python, so we started with some "easy understandable" examples. after this 1 hour lesson, almost everyone should be able to follow our next videos ;)! So I'm sure you won't get bored in our next videos :)!
filefactory and uploaddot are good. you might consider github as a possible if you don't have a paid account and don't want your downloads to expire. just thoughts. nice video.
Patrick and Rene, Fantastic!
I think this is a really great start and I look forward to the rest of the series. My recommendation would be to take various topics like LAN attacks, Wi-Fi attacks, Malware analysis, Debugging etc. and show the application of Python in each. This would address a wide audience coming to SecurityTube.
Another small recommendation would be to also write some details about what is presented in the video in the description field. For a new user to your series, this will help a lot in making him hit the play button :) After that I am sure he will be hooked.
great job!
Show me the Snake !!!!! This could breach regulations .
Thank you Patrick and Rene. I know just how much work there is in preparing such a presentation. I'm pleased that you've allowed download of the video(s) from Vimeo because it's very useful to have them available when offline.
I'm looking forward to the next video!
@everyone:
Thanks a lot for your valuable remarks and compliments. We are taking all of them seriously and are trying to incorporate your feedback into the development of further episodes. We are also open to critique in the form of "rene should try to speak up a bit and stop using this hypnotic voice..." :-)
@vivek:
Thanks a lot for your compliments and for your recommendations! They are most valuable to us. I personally would like to do a few "out of band" episodes for advanced hackers, too, which don't necessarily follow the natural didactic flow "from basic to advanced" in teaching python, sockets, sync/async, select, threading, etc. Note taken, gratefully, inspiration shall follow :)
@andrew: yeah, thanks man for pointing that out. i should have thought of that, too :-). having an online src repository, even if it's just for (till now) little example code. brilliant idea. i prefer mercurial myself but maybe it's really time to give git a try now.
Again, we are really craving and grateful for feedback, be it positive or negative. At the end of the day people's opinions are their opinions and if they help us to improve our work, ultimately the whole community will benefit.
So keep 'em comin'. The community is listening.
Patrick and Rene thanks guys,strong and very good starting "python" take care of the bites,and as my friend @ranamann says The community is listening.
Patrick and Rene thanks from Russian hackers :) Good job!
@Machine:
Fellow Russian hackers: you're very welcome, I take your post as an honour! Thanks a lot!
-Rene
PS: Before any misunderstandings occur: Of course, everyone is welcome here. ;-)
WOW! thank you, great video!
I can't wait the second, good job!
@Vivek: thanks for your compliments! your feedback is also very nice... we will think about how to cover all that stuff in one primer (or like Rene said maybe in some additions) ;)!
@machine:
also thx from my side! I'm glad to see that some Russian guys are following our primer :)!!!
of course thx again @all! all your feedback ends up in pure motivation in producing part2!!!
I have been searching for something like this for very long now. Well explained theory, combined with clearly understandable examples makes this kind of videos incredibly valueble. This video series will not only help me understand networking principles but it is going to improve my understanding of Python programming. Rarely have I seen somebody go through Python code in such detail, something that is very importan for a beginner. I am looking forward to see how this primer is going to develop and want to say a huge THANKS to you Patrick and Rene and of course to you Vivek for bringing this platform to life and inspiring people.
Thank you Patrick and Rene. Looking forward to more on scapy as well.
Great work! I really liked the concept of two people working together on the same video. I think it was well explained, I understood what every single line of the python script does, and the introduction to scapy opens up a whole world of possibilities for me. I want to thank you both.
As far as suggestions goes, it would be really helpful to add references to reading material wherever is appropriate: books, articles, papers, etc.
Thx for all the nice feedback!
@arcadio:
We already thought about providing some materials as well... but this could take some time. maybe we will refer to some books as well at some point... (if we don't cover something in detail).
been looking fwd to this video and when I got finished installing flash on bt5 I thought "what will I watch first?"
So I came here. Breaking this installs cherry with a youtube video just didn't seem to share the spirit of the thing LOL
Hello fellow securitytubers!
I have created a simple free file hosting service where you can share your code with the community on securitytube. It's a free hosting shit, but it will be good to share code. We don't need file hosting services where we have to wait 60 seconds to download the code or get spammed with popups.
Here is the link for our filesharing:
http://codehost.xtreemhost.com
Register (no confirmation email and no email sharing), login and share the code.
File size limit is 4Mb so use it for sharing code or images etc.
Remember this is just a simple file uploading "service" so security is at very low, and this is just for community sharing, not for private stuff because I'm not responsible for if you upload some critical files (you can, password protected).
Thanks.
Change, new url:
http://code-host.co.cc/
@netinfinity - Thank you netinfinity for providing such a resource. I'm sure it will provide quite useful.
@Andrew - I hope people will use it because it's simple and no need for "third party" hosting services.
Another thing is if people are interested I can write an pastebin + hosting app for securitytube for easier sharing.
@netfinity:
cool, thanks mon! we actually think about either creating a git repository for this primer (just because it will stay online forever) or if we use the server provided by you! To be honest, I think we will use both ways to provide our files in this Primer! Then everyone can decide for what he prefers :)!
We really appreciate this nice gesture!
The spirit of this community is definitely growing :)!!!
@WCNA: sorry.. I forgot to give you an answer! "you'll get some"!!! I will start with the "cool stuff" in the next video. Rene is preparing some nice code as well ;) ...so stay tuned
This is one of the best and entertaining videos I have seen. Thank you guys very much for your time and effort! Your contribution is greatly appreciated! I have spread the word. I really enjoyed how well spoken but down to earth you both were. Very detailed, very focused, and very informative yet also laid back just enough to not be boring! Please keep it up!
Guys, you've done a brilliant job here. First of all your 'laid back' and steady voices make this a really chilled and enjoyable experience. It was a pleasure to watch and I stopped only to type in the examples and interact.
The examples were interesting, the dual presenter approach with both Patrick & Rene works really well and the 'intermission' midway for a look at Scapy was really well timed. An excellent job and I thank you both very much for taking the time to do this, and I seriously look forward to the next instalment.
I was left with a much better understanding of Python and immediately able to expand on the examples and have some fun looking at different server responses.
If I could just raise a couple of clarifications for anyone who is really just starting out with Python - these caught me out.
The first is the importance of 'whitespace' in Python. Other languages use things like {} curly braces to mark blocks of code. Python does not - it uses indentation like tabs or spaces instead.
try:
this
Python lines don't end with a semi-colon ; no matter how hard you try :-)
THREADS
Because the characters are small and hard to see on a screen-cast, it is probably worth clarifying if there is any subtle difference between using a single quote ' and a double quote " - I'm making an assumption here it may behave like Perl?
Unfortunately I hit 'enter' on the above post before it was ready to go!
Basically -
try:
[tab] this
#not
try:
this
The only other note I made was 'THREADS' - and I wonder if you can look at child processes and interprocess communication in a later video? If someone is trying to write a slow-loris type of tool in Python, it may well be really handy :-)
Again, really great video - first class and totally enjoyed it. Got a great deal out of it too. Thank you gentlemen very much for your time.
Barry
We are back online! www.code-host.co.cc
You can host your files now :)
@netinfinity:
cool, thx a lot again!
I've uploaded it now to your site!
http://code-host.co.cc/files/PyPrimer1.tar.gz
@Barry:
thx for your compliments :)!
Hint:
you can create a vimeo account for free and download the vid in 720p (also for free)!! it's easier to follow our code in "HD"! :)
Also thx for your clarification for "python n00bs" :)!
@all: nevers stop learning and keep your motivation!
I think I actually don't get how to post the link :D
Thanks everyone for your great comments, recommendations, and also your efforts in taking part and helping out here and there! It's really nice and an honour to be part of this active and helpful community.
@Blackmarketeer: Thank you for your very nice feedback, your great comments, and valuable insights. I highly appreciate them and I am sure they'll help lots of python beginners!!!
BTW: Threading will be covered sooner than you might think :).
@securitytubewhyjoseph: wow, thank you! also thank you for spreading the word, helping securitytube to grow!
@mr_insecure: still laughing about your subtle "littel" joke :)
@pymp, @Ignatius, ..., and @all: again, your feedback truly is a great source of motivation and inspiration for us. apologies if we don't reply to everyone personally but you all deserve a big thank you. Patrick and I are doing our best to compensate you with the upcoming videos. we will progress into more advanced stuff "quite quickly", because python allows us to do so :)
really thk, i was looking out for something like this and finaly i found it
You mean: http://code-host.co.cc/files/PyPrimer1.tar.gz
LInk should be copied in the new tab to work...hmm.. working on that
Hi everyone!
I have uploaded the HD version of this video to vimeo. You can find it here: http://vimeo.com/24570637
Patrick told me it will very likely take a few days before the securitytube page here will reflect the switch-over to the new HD source so I thought I'd share the direct link to it here.
All the following parts will be in HD from the very beginning... C001, eh? :-)
Again, thx for all your help and feedback, part 2 is in the making, so stay tuned... :-))
Nice one. Keep up the good work.
I encoded HD version of the video in just 44mb..
you can grab it here...
http://www.mediafire.com/?m1c5wgnonqb29ns
@infogeek: good lord!!! i had to see it in order to believe it! the quality is astonishing for just 44Mb! the crystal clear and sharp text in the terminal windows.... impressive!!! now, if you could get it down to 4.4Mb it might fit on a floppy disk ... - just kidding :-).
thanks for this, this adds great value to our fellows with low bandwidth / disk space!
Thanks for a really nice job of introducing both Python and scapy as tools of the trade and linking it to WireShark/pcap files.
Thanks guys,
This has been fun to play along with and has been well explained. I'm now of to find the next video in this series