Writing a Bittorrent tracker
Yep, that time again, decided I need a new project to work on and seen as I am not too busy these days, a bittorrent tracker seems like an ideal project. I found something called TBsource which is used to build a tracker so I am going to base it off of that. I kinda suck with SQL so this will be a good chance to get some more exposure to it and increase my knowledge base, Oh one more thing, I need a graphic designer for this, it’s for a simple logo so if your up for it then catch me online (see “about me” for contact details).
New hard drive!
It was my birthday on the 2nd of April, was a pretty darn good day…now I’m officially 19! Getting older. Oh I also got a new Western Digital Elements hard drive, been running out of space recently so it was a good choice. Its 250GB so has enough to backup all of my media onto it, the only problem I found was that you cannot write single files over a certain size onto it, confusing. I was trying to write a 4.7GB .ISO image to it and kept on getting the error message that the disk was full, well it certainly was not the disk as it had over 100GB free. After some searching I noticed some people talking about file size restrictions of the file system which were there to stop big transfers from one drive to another. The file system of my drive is FAT32, am still trying to find a solution to this apart from splitting the .ISO into smaller chunks.
Apart from that it’s a decent drive, has USB connectivity so very portable (saves me cash on DVD-R’s) and has its own external power supply. The noise level from it is lower than I was expecting, sick of hearing hard drives whirling away when I am trying to sleep heh. I would recommend this drive to anyone that needs a backup or just a spare drive to store their data on.
SELinux and servers
I decided to make a new post as I’ve neglected this blog and not posted sod all on it for months now. So the last few days have been spent working on assignments and reading about setting up SELinux on servers. I took the plunge and installed it on my Gentoo server, I have lots of tweaking to do to configure it to how I like but is definitely worth it. Check out the page on this project on the Gentoo site here.
While I was at it I looked into securing my PHP installation because I’ll be using this on the server, something that looked interesting is Suhosin – the hardened PHP project. I have a few doubts installing this right now because I heard it can damage PHP application and will take lots of modification to get it right and working well. I’ll document the stuff that is critical first and then look into any potential glitches that could arise from this. It should be finished by this Friday sometime so I’ll come back and tell you all how it went. Information on the Suhosin project can be found here.
WinBNC – How to use an IRC proxy
So most of the readers here are probably in school, college or work and may want to connect to IRC but are blocked by those pesky firewalls and port filters. In this short guide I will show you how to configure and install WinBNC 2.8.2 so that you can connect to IRC from wherever you want.
This isn’t only to connect from the outside world, you may be on a network where only one computer is directly connected to the Interne or you might be a server admin and want all connections going through one computer to limit damage from Internet based threats to the other computers on the network. I will provide a link to where WinBNC is located for you to download.
Introduction: Now you probably want to know how WinBNC works before you start using it. I can’t go into great detail (hence “short guide”) but will give an overview. Basically WinBNC will sit on a computer and listen for connections from other computers; once a user is connected he/she can then connect to another server. This is how it will look like -
Computer user > BNC > Server user wants
Now a firewall will normally block IRC connections directly to the server that a computer user wants which is where a BNC will come in handy. The BNC will listen on a port that is allowed access to the Internet, for example port 80 which is for standard HTTP traffic and then the user can connect to the server from there. If a user was allowed access to the server the connection would look like this -
Computer user > Server user wants
Configuration: So now you will have downloaded the file which contains two files, bnc282.exe and bnc.cfg. Extract these files to a location on your computer; the desktop will be fine. Now this is where we need to edit the files so you can use BNC.
In the folder that you have extracted the files to you can now open bnc.cfg with a text editor, you can use notepad for this. Now go to the line where it says listen. The default port for this is 9000 but I recommend you change this to 80 as it is hardly ever blocked.
Under that line you will see a line that says password. As usual change the default password of testpass to your secret password.
Under that line is the admin password. This is the master account so make sure not to use the same password as in the first one.
Under that line you will see the word allow *. The * means that any computer on the Internet will be able to connect to your BNC. If you know the IP address you will be using you can delete the star and only allow that one computer access for extra security measures.
The configuration is now complete. Take a deep breath. On second thoughts don’t, it wasn’t that hard now was it
Using the BNC: Now that the configuration has been completed you can run bnc282.exe, this piece of software will now listen for connections.
To connect to your BNC you will need to use an IRC client. mIRC is a free and commonly used one for Windows. So now you know the IP that the BNC is listening on you can type the following –
/server 192.168.2.4 :80
This will now connect you to your BNC on port 80, the port that was set to listen in the configuration file. If all is well you should see the message –
192.168.2.4- You need to say /quote PASS <password>
Success! You can now type –
/quote PASS <your password>
Obviously it won’t be <your password> but the password that you chose in the configuration file earlier. Now if you entered the password correctly you will see the message -
192.168.2.4- Welcome to BNC v2.8.2, the irc proxy
————————————————————
192.168.2.4- Level two, lets connect to something real now
————————————————————
192.168.2.4- type /quote conn [server] <port> <pass> to connect
————————————————————
192.168.2.4- type /quote help for basic list of commands and usage
All you have to do now to connect to an IRC server is type
/quote conn irc.rizon.org
This will connect you to an IRC server. Change the server from irc.rizon.org to the server that you want to connect to. That is all there is to it. I hope you enjoyed the read.
Credits: I would like to say thanks to the programmers who created BNC. Without it this blog entry wouldn’t have been possible. For more information on proxies here are some links you might find interesting -
BNC: http://en.wikipedia.org/wiki/Bounce_%28network%29
BNC download link: http://www.megaupload.com/?d=3HCFAOHL
Gallery2
I managed to install WAMP (Windows, Apache, MySQL, PHP) a few weeks ago now and decided to make some use of it. I have already installed wordpress locally which was quite a challenge. Today however I found out about an application called Gallery2. This is like flickr but you have the ability to manage all of your photos instead of uploading them. It’s very customizable and there are plenty of modules available that you can download, install and use. It’s taken me about an hour to install and using the install guide at life hacker helped me more.
The only problems I occurred was with creating the database, I finally figured it out in the end after reading through the MySQL FAQ for 30 minutes. Turns out it was as simple as using the point-and-click phpMyAdmin tool to create the database. I would recommend this to anyone that wants to mess with photos, anything to do with that nature. Great for creating photo albums. Be sure to follow the correct security procedures before putting your server online; just a word of warning. Here is a sample of what my album currently looks like
Links: http://lifehacker.com/software/digital-photos/hack-attack-host-your-own-photo-gallery-with-gallery2-218755.php
http://codex.gallery2.org/index.php/Gallery2:Download#Packages
Hash cracking made easy
Thought I better post something on this blog seen as I registered it, in what seems like donkey years ago. So what can I post? Right people keep asking me this question, “How do I crack password hashes” I guess I should answer it for all the people who don’t know yet.
Introduction: Now in Microsoft windows operating systems, passwords are stored as hashes. The hashes are LM hashes and are stored in the SAM config file of system32, The path to the SAM config is C:\WINDOWS\system32\config. In this file is a file called SAM which is incidentally, the file that stores these passwords is loaded on boot-up and therefore not possible to load once you are logged in. Luckily with the help of some handy tools the password hashes can be retrieved relatively easily.
Retrieving the hash: So before you can start the process of cracking the hash files you first need to get them. To do this we will use a tool called pwdump2. pwdump2 uses dll injection to access the hashes. First download pwdump2 from this site http://www.bindview.com/Resources/RAZOR/Files/pwdump2-orig.zip
This file will be detected by various anti-virus programs so be careful if you are using this at work. Next you will need to extract two specific files in order for this method to work. The files you need to extract are pwdump2.exe and samdump.dll. Once these two files have been extracted to a location on your disk, open up command prompt and locate the directory. If for example the files extracted are on the root of C:\ you will type “cd C:\pwdump2″. When you are in this directory it is time to run pwdump2. It is best to save the results into a text file. To do this type “pwdump2 >hashes.txt” and the contents of the SAM file will now be in that directory.
Cracking the hash: So now you have the hash in plain text it is time to crack the hash. The hash should look something like this admin:1016:23f25eecf9db0ed329830e3216a18f95:39d4d689ba4b88b30944232f2ba5f81a:::
Now we are going to crack this hash using the #rainbowcrack IRC channel located on the server irc.governmentsecurity.org. Connect to the server and join #rainbowcrack. In the channel you should see a bot with the nick of “C3P0″ To add your hash type “.c3p0 addlm <yourpwdump2hash>” make sure that you include the full line of the hash that is in the text file with the hash results of you will receive an error.
Now if that all went to plan, the bot .c3p0 will have added your hash to the queue and will attempt to crack it when there are slots free.
Now idle in the chat and wait for the plain-text value to be displayed in the channel. It took no longer that 15mins to crack the hash I submitted, I was given the message “C3P0: Login: zorin->admin Passwd: %invincable% hex:25696e76696e6361626c6525″
Credits: I would like to thank the team who provided the rainbow tables for this experiment. They have a site located here: http://www.plain-text.info.
Also a shout out the programmers of pwdump2.
Thanks for reading; I hope that cleared any questions up.
Look!
When I figure out something good to post on here, I will. Until then wait and stop complaining for the lack of content.
-
Recent
-
Links