Category : "Coding"

All kinds of Programming.

Python program to fetch domain whois data using sockets

Whois The whois information of a domain name provides various details like registrar, owner, registration date, expiry date etc. The whois information is provided by the corresponding whois servers of the registrars. The first step is to contact whois.iana.org which provides the actual whois server of a domain name. Next the particular whois server is contacted which provides the full whois ...

Programming udp sockets in python

UDP sockets UDP or user datagram protocol is an alternative protocol to its more common counterpart TCP. UDP like TCP is a protocol for packet transfer from 1 host to another, but has some important differences. UDP is a connectionless and non-stream oriented protocol. It means a UDP server just catches incoming packets from any and many hosts without establishing a ...

Programming raw udp sockets in C on Linux

Raw udp sockets Raw udp sockets are used to send manually constructed udp packets. The udp header can be found in RFC 768 and has a very simple structure as shown below. 0 7 8 15 16 23 24 31 +--------+--------+--------+--------+ | Source ...

Raw socket programming in python (Linux)

Raw sockets allow a program or application to provide custom headers for the specific protocol(tcp ip) which are otherwise provided by the kernel/os network stack. In more simple terms its for adding custom headers instead of headers provided by the underlying operating system. Raw socket support is available natively in the socket api in linux. This is different from windows where ...

Syn flood program in perl using raw sockets (Linux)

Syn flood program sends out a large number of syn packets to a destination host such that the destination host gets under heavy pressure to reply to all of them and hence consumes huge amount of memory/cpu resources without any real purpose. This causes the services of the remote host to become unavailable to legitimate users. Hence the name denial ...

Syn flood program in python using raw sockets (Linux)

Syn flood and raw sockets A syn flood program sends out large number of tcp syn packets to a remote host on a particular port number. Syn packets are intended to initiate a tcp connection. However if a large number of syn packets are send without any purpose, then then it would consume a lot of resources like memory on the ...

Send html emails in php using the mail function

The mail function of php can be used to send not only plain text emails, but html emails too. The documentation page shows how to do that. Here is a easy to use function that does the task and has a form very similar to the mail function. function html_mail($to, $subject, $message, $options) { if(isset($options)) { $headers = "From: " . $options . "<".$options.">" . "rn"; } $headers ...

Fill text templates using arrays in php

Text templates are often used to generate content like notification emails, invoices filled with the details of a customer or user. The best example would be a bulk email program that sends out emails to multiple users filling the details of the particular user in every individual mail. Text templates have place holders for fields which can be filled using an ...

Php tutorial – Parse html DOM with DOMDocument

Domdocument The domdocument class of Php is a very handy one that can be used for a number of tasks like parsing xml, html and creating xml. It is documented here. In this tutorial we are going to see how to use this class to parse html content. The need to parse html happens when are you are for example writing scrapers, ...

Perl socket programming tutorial

Tcp/IP socket programming Sockets enable your program or application to talk to other machines over the network. When you type in google.com in your browser, it talks to google.com over the internet and fetches the webpage. For socket programming we need to use the socket library or api which provides some very simple functions to do such a network communication. In ...

Pages:«123456789...19»


Connect with us