Python is an an interpreted, interactive, object-oriented programming language , which is using by almost every Big Organizations like : Google, Facebook, and etc. And specially in the field of Artificial Intelligence, Data Science every computer programmer is using python to conduct their daily tasks But python is an language which is also used by hackers, penetration tester and bug hunters, because of its amount availability with good modules inside it that can be used for all kind of PT tasks.
You don’t need to search any tools for hacking around the internet or github. if you have a better understanding of using python as an toolkit @ankitdobhal.
Table Of Content
- Introduction To HackTheBox?
- How To Use Python Script To Get InviteCode?
- Summary Of Python Script
Introduction To HackTheBox?
HackTheBox is an platform for newbies and other hacking aspirant for testing their knowledge by doing penetration testing task , Capture The Flag Challenges, OSINT Challenges and all other PT tasks. But one of the interesting and cool thing about this platform is that when you try to signed up in HTB it asks you to give a unique Base64 converted Invite-code. And to get this unique invite code you need to access or can be said that you have to hack this. But its tough for beginners and its also time consuming tasks even their are some tools like Burp, Curl but we have great option for this So “Take a look at next section“.
How To Use Python Script To Get InviteCode ?
Even though at the starting of this blog we all have understood that python is used by most of the good Hackers because of its easy use cases with super helpful good modules / libraries . So here is a small python script designed using python by AnkitDobhal.
You can download in official website using wget command given below.
So now you have the Invite Code So you can join now hackthebox and after joining you will this screen with lot of PT labs.
Let’s try to understand that what is actually the above cool hack script HTBHACK doing behind scene with some steps.
- To access the this unique Invite-code we have to access hackthebox invite generator api which we can find using developer tools of any cool browser.
- To do post request requests module can be used, with headers for User-Agent
- To read the post data after response use json module.
- Then at last to decode it into base64 use base64 module.
invite_code = base64.b64decode(encoded_data)
So now you all know how powerful is python that you can use as your toolkit but to know more about the whole script you can DM me on Linkedin
A keen learner and passionate IT student. He has done Web designing, CCNA, RedHat, Ethical hacking, Network & web penetration testing. Currently, he is completing his graduation and learning about Red teaming, CTF challenges & Blue teaming.