How to Code a TCP Connect Port Scanner in PHP

By | August 11, 2020

A port scanner is a program designed to probe a server or host for open ports. Looking at open ports, one can tell what services might be running on the remote server. We earlier made a TCP Connect port scanner in C here – https://www.binarytides.com/tcp-connect-port-scanner-code-c-winsock/ and here – https://www.binarytides.com/tcp-connect-port-scanner-c-code-linux-sockets/ Now we shall try making the… Read More »

PHP strtotime in 64 bit environment

By | October 23, 2011

The strtotime function is used to convert a date in various formats to a timestamp. However its behaviour is different based on architecture it is running on, whether 32bit or 64bit. Lets take a few examples : In 64 bit environment desktop:~$ php -a Interactive shell php > echo strtotime("0000-00-00 00:00:00"); -62170005200 php > echo… Read More »

Get smooth and beautiful fonts on Ubuntu

By | May 9, 2020

To get beautiful and smooth fonts on Ubuntu : 1. Install ttf-mscorefonts-installer from synaptic This will provide the fonts like microsoft arial , tahoma , verdana , courier etc. 2. Get the xml file by Obi Bok from https://wiki.ubuntu.com/Fonts The above xml file provides special finetuned settings for antialiasing and hinting parameters for various fonts… Read More »

Play VCD on Ubuntu

By | October 1, 2011

If Totem , the default movie player does not play vcds properly , showing file permission errors , then try : 1. SMPlayer Install from synaptic : sudo apt-get install smplayer 2. mplayer Install from synaptic : sudo apt-get install mplayer 3. KPlayer Install from synaptic : sudo apt-get install kplayer To play from terminal… Read More »

Display hindi unicode fonts on Google Chrome on Ubuntu Linux

By | September 29, 2011

Google Chrome has problem displaying hindi/unicode and other Indian language fonts. For example bold hindi fonts might be displayed as square boxes. http://code.google.com/p/chromium/issues/detail?id=32109 http://code.google.com/p/chromium/issues/detail?id=21320 It is some kind of font selection bug. Lets try fixing it. 1. You may want to install the packages ttf-devanagari-fonts and ttf-indic-fonts. Also get that mangal.ttf thing from windows or… Read More »

Convert vcd dat file to mpeg on ubuntu

By | September 28, 2011

VCDs that are played on vcd players often contain the video in dat format. The dat format is internally mpeg only but has some additional header information attached. So the mpeg portion has to be ripped off to get the mpeg format. Once converted to mpeg format, it can be processed inside any video editor…. Read More »