Internet Security and Ethical Hacking

Internet Security and Ethical Hacking

Welcome to the unique confluence of hackers , crackers and security professionals
on the world wide web.
This is your complete resource for internet security and ethical hacking.

Ethical Hacker -: The Ethical Hacker :-
Most people think that hackers are computer criminals. They fail to recognise the fact that criminals and hackers are two totally different things. Media is responsible for this. Hackers in reality are actually good and extremely intelligent people who by using their knowledge in a constructive manner help organisations, companies, goverment, etc. to secure documents and secret information on the internet.


WELCOME TO ALL VISITORS

PLEASE BOOKMARK THIS BLOG FOR DAILY UPDATES. FOR HACKING TIPS GO TO COMPUTER SECTION. FOR MORE INFORMATION CONTACT US .
Your Ad Here

SEARCH FROM HERE

Tuesday, November 10, 2009

FOOT PRINTING CONTINUES......:)

Yesterday I have explained You all that How to collect information about the Websites and organisations....
Today i will continue With Footprinting and take you to some more deep level... And then tell you how to make Blueprints from them.. So read on....



UNEARTHING BASIC INFORMATION

First of all We will focus on Unearthing the Basic Information about the site... i.e the IP and server informations..
I will Show you with the help on snapshots :
First go to START --> RUN --->type cmd--->then type tracert www.websitename.com
Here we will use two basic commands in command Prompt(cmd): tracert www.webistetobeanlysed.com

and ping www.websitename.com

It will look something like this:



Here I explain what it shows...
We trace routed www.amulive.com
1. Shows Our Gateway of connectivity.
2. Shows our Outgoing Footprint Ip(i.e the our IP that is being analyzed by website)
3. Shows Connectivity passes through which service Provider. I uses BSNL but its showing airtel because I prefer DNS of Airtel for surfing Quick).
Next steps showing the Ip's of Webservers through which amulive is being maintained.

After This We will came to now the IP of the Website and Ip of itz web servers which are being used further.
website Ip can be used to gather more information about the website..

How to Find The Personal Information About the Individual Over Net ??
Its one of the Most important task. Its also helpful in finding the fake profiles... But unfortuantely this is limited But we can use it to the Most... There are two website which will help us...
1. http://people.yahoo.com ( best Site To trace People for their Personal Information and also reverse Phone or mobile number Look up)


2. http://www.intellius.com ( But this site is limited to US only)



Sample Report from Intellius :

Satellite Picture of Joe's House from Intellius:



Now Using these Sites you will be able to collect the personal information of the individuals and also being able to identify the fake profiles..


TOOLS NEEDED FOR FOOTPRINTING :

You can avoid above hectic work by using this tool : SpiderFoot
Download link: http://www.binarypool.com/spiderfoot/

Information about SpiderFoot:


SpiderFoot is a free, open-source, domain footprinting tool. Given one or multiple domain names (and when I say domains, I'm referring to the DNS kind, not Windows domains), it will scrape the websites on that domain, as well as search Google, Netcraft, Whois and DNS to build up information like:
  • Subdomains
  • Affiliates
  • Web server versions
  • Users (i.e. /~user)
  • Similar domains
  • Email addresses
  • Netblocks

ADDITIONAL FOOTPRINTING TOOLS :

Note all these tools are freewares .. U can easily google then and download these..


~ Whois
~ Nslookup
~ ARIN
~ Neo Trace
~ VisualRoute Trace
~ SmartWhois
~ eMailTrackerPro
~ Website watcher
~ Google Earth
~ GEO Spider
~ HTTrack Web Copier
~ E-mail Spider


This is all about Footprinting . Now Use the Gathered information to make basic Detailed Information about the Website/person...

I thinks This is Enough for Today. Please Comment . If you have any queries Post them in form of comments. DON'T FORGET TO SAY THANKS AND PLEASEE COMMENTS....

DARK MASTER

Monday, November 9, 2009

Download keylogger : FUD Keylogger Remote spy keylogger software




Now, I am adding one more article to download keylogger. This time its FUD remote spy keylogger software. Yes, this remote keylogger software created by General Dee is not detected by any antivirus available. Download keylogger software and try it out to hack email password. I have provided link to download keylogger software in this article.

What is Keylogging???

I found many newbies are visiting this blog and hence, introducing you what it keylogging. Basically, Keylogging is the process of creating server keylogger and then sending this server.exe file to the victim. Once the keylogger server is installed on victim computer, all text and passwords typed on his computer are sent to you in your email inbox by this server created using keylogger. So, you get his typed passwords and thus can easily hack his email password.

Also, server keyloggers are detected by antiviruses. So, you need to have FUD (Fully UnDetectable) keylogger so that victim computer’s antivirus will not detect your sent server keylogger as virus and prevent it from being deleted. This keylogger is 100% FUD as of today’s report says.

How to scan this keylogger file???

As already mentioned, this is FUD Keylogger software. There are very few FUD Keyloggers on web. So, we have to take efforts to keep this FUD as long as possible. This will benefit all of us. So, if you wanna scan the server created by keylogger, follow the steps below to help this keylogger remain FUD.

1. Go to http://scanner.novirusthanks.org/ and upload the created server keylogger file from your computer.

2. Now, check “Do not distribute the sample” to avoid this from being detected by antiviruses. Now, hit on “Submit File” and you’ll get antivirus report.

This is necessary because almost all other online scanners have tendency to redistribute virus detected sample to all other online scanners and hence, almost all antiviruses detect our created server as virus. Thus, our server no longer remains FUD. So, always scan FUD hacking softwares at novirusthanks.org as I have mentioned above.

Download Keylogger - FUD remote keylogger software:

1. Download keylogger software to hack email passwords.


2. Unzip the downloaded file using winrar or winzip to unlock remote keylogger software.

3. Now, run “General Keylogger v 1.o.exe” file to get something like this:

. Fill in your email address and password. Fill in email address where you want to receive the typed passwords. In “Send logs every” field, adjust time in minutes as you like. If you are using this for testing purpose, make it 1 or 2 mins for faster testing. In Server name, fill anything you would like as server file name. Also, you can check “Enable Anti’s” which enables following features:
- Anti Wire Shark
- Anti Kaspersky
- Anti Anubis
- Anti Virtual Box
- Anti VMWare
- Anti Virtual PC
- Anti SandBoxie

These features prevent detection of keylogger on victim computer.

5. Now, you can send this server file as it is or you can use Binder software to bind this server keylogger file to any .mp3 file. This prevents victim doubt. No need to use Crypter software as its already FUD.

6. After victim has installed our sent server keylogger file on his computer, keylogger will start recording typed keystrokes in logs and send these logs to your email address. Thus, you will start receiving emails of such type containing victim passwords.


Click on image to view enlarged size
You will require to have Winzix to get remote keylogger software.
Thus, you can now hack email passwords using this remote keylogger. Simply download keylogger and use this remote keylogger software to hack email passwords. If you have any problem in using to download keylogger and use this remote keylogger software to hack email passwords, please mention it in comments.

Enjoy n download keylogger software to hack email passwords…


EVERY INFORMATION PROVIDED BY OUR SITE IS ONLY FOR EDUCATIONAL PURPOSE. IF SOMEONE MISUSED THEM THEN WE ARE NOT RESPONSIBLE AND ONLINETECHNICALTUTORS.BLOGSPOT.COM IS ALSO NOT RESPONSIBLE.

DON'T FORGET TO SAY THANKS


All-Spy Keylogger : Spy Software to monitor activity on computer

Today, I will inform you about one more keylogger All-spy keylogger to monitor activity on your computer. All-spy keylogger provides you with features which many other keyloggers lack. Download All-spy keylogger and try it out on your computer.

All-Spy keylogger to Monitor activity:

All-spy keylogger is all in one keylogger package. If you want to monitor victim activity stealthily, then this keylogger is for you. It has all features that are necessary for a monitoring software like:

# Keystroke recording.
# Sites recording.
# Records chat conversation.
# Records applications run on computer (what other keyloggers lack)
# Monitors printer devices and their activities. (other keyloggers lack)
# Clipboard monitoring.
# Captures screen.
# Keeps track of changes in file system, changes in files and folders (other keyloggers lack)
# Email delivery of recorded logs.
# FTP delivery also supported.

What more… it hides itself from all popular firewalls, antiviruses and also not shown in Task Manager. The user has no idea of keylogger being installed on his computer. Also, keylogger restarts itself on every computer boot.

How to use All-spy keylogger:


1. Download All-Spy keylogger to monitor activity of victim.



2. Install the downloaded all-spy keylogger software. Run the keylogger software. It will ask for password. Enter user as your password.

3. Now, you will see something like this:

Allspy keylogger

4. In settings tab, you can enable email notifications of activities and even get logs via FTP. Just check “Enable Email notification” and in popup box, type in your email address. You will start receiving all logs from All-spy keylogger.

Allspy email notification

5. Now, All-spy keylogger will start monitoring activity on computer and start sending all activity updates. Thus, you can easily monitor victim activities.

6. All-spy keylogger is very useful if you get physical access to victim computer (even one time access if enough). Simply install this keylogger on victim computer and enable Email or FTP notification. You will start receiving all keystrokes typed by victim.

Thus, you can now use All-spy keylogger to monitor activities on your computer. All-spy keylogger is perfect spy software which is available with all features an ideal keylogger should have. If you have any problem in using All-spy keylogger to monitor activity on computer, please mention it in comments.

Enjoy All-spy keylogger to monitor activity on computer…


EVERY INFORMATION PROVIDED BY OUR SITE IS ONLY FOR EDUCATIONAL PURPOSE. IF SOMEONE MISUSED THEM THEN WE ARE NOT RESPONSIBLE AND ONLINETECHNICALTUTORS.BLOGSPOT.COM IS ALSO NOT RESPONSIBLE.

DON'T FORGET TO SAY THANKS.....



Download Keyscrambler Full : How to protect computer from Keylogger

I am writing this article to inform you about Keyscrambler software which protects your computer from keylogger. I have even provided link for Keyscrambler software download.


Keyscrambler to protect computer from keylogger


Keyscrambler - Protect yourself from Keyloggers:


Keyscrambler is a encryption software which encrypts all keystrokes typed on your computer. Due to this encryption, keylogger present on your computer records encrypted value of typed keystrokes which is fake. Thus, even when keylogger is present on your computer, you have no fear of getting your passwords hacked as Keyscrambler always run in background encrypting your keystrokes.



How to use Keyscrambler???

Now, just follow the steps below to know how to use Keyscrambler software.

1. Download Keyscrambler software to protect your computer from keylogger.



2. Unzip the downloaded file using WinRar free keyscrambler software.

3. Now, run “KeyScramblerPro_Setup.exe” file on your computer and complete installation. Restart your computer to allow Keyscrambler to start its working.

4. On restart, Keyscrambler will ask for Registration information. Open “Serial.txt” file in downloaded folder and enter information and hit “Verify”.

5. Thats it. Now, Keyscrambler application will start encrypting your typed keystrokes on your computer thus, protecting you from invisible keyloggers. To check its working, simply go to say www.gmail.com and enter will email id-password. You will see Overlay Window at top left showing the encrypted value of your typed keystrokes.

You will require to have Winrar to get free Keyscrambler software.


Thus, you can now protect yourself from invisible keyloggers using this Keyscrambler software. Simply download and install Keyscrambler and forget about hacking by keyloggers. If you have any problem in using Keyscrambler software to protect from keylogger, please mention in comments.

Enjoy Keyscrambler software to protect from keylogger…


Don't Forget To Say Thanks....

TYPE OF VIRUSES

Timifonica. This virus was known in 2000. It was a virus that sent text messages from infected PCs to phones.

Trojan. It is considered the first virus sent from cell phone to cell phone. It was known in August 2004. The Trojan was created as an anti-piracy program the game Mosquito against illegal distribution. The virus sends itself through SMS text messages.

Cabir. This virus was known in July 2004. It was a creation of group 29a. This virus is spread through Bluetooth to accessible phones. It is spread as an SIS file (Symbian OS distribution file). Cabir attacks phones with Symbian OS. When the phone is infected it displays the message ‘Caribe’.

Commwarrior. This virus appeared in March 2005. It infects phones with Symbian OS. The Commwarrior worm spreads itself through Multimedia Messaging System (MMS) following the address book list.
Comwar. This virus worm is spread through MMS messages and Bluetooth. It also attacks phones of Symbian Series 60 OS.
Duts. This virus is the first to infect cell phones and Pocket PCs. The Duts attacks the .exe files and files that are bigger than 4096 bytes.

Skulls. If a cell phone is infected with this virus, then the desktop icons are replaced with images of skulls. The Skull makes all phone applications useless.

Lasco.A. This virus spreads through Bluetooth and also can be attached to files. The Lasco.A is a result of mistakes in cell phone program. It is also present in PCs.

Hack Airtel GPRS: Airtel free GPRS trick/hack

I have written this article to inform you about airtel free GPRS trick/hack.


Airtel free GPRS hack:

1. Download Airtel free GPRS browser to hack airtel GPRS.



2. Unzip this file using winrar obtain Airtel free GPRS software.

3. Now, install this browser in your mobile. This Airtel free GPRS browser is same as Opera Mini browser, but this browser is modified to use proxy server to get Airtel free GPRS.

4. After installation, press Accept and OK sequentially and get Mobile Office settings from Airtel. Start airtel free GPRS browser using Mobile Office as Internet access profile and you will start using Airtel free GPRS. Thus, we are able to hack Airtel to get free Airtel GPRS.

Note: In some cases, you’re charged 30 paise after exiting from browser. You can surf as many sites as you can and then after exiting, you’ll be charged only 30 paise for that session. So, if you don’t wanna lose any money, simple logic is to not to exit from Airtel free GPRS browser. Just keep it minimized and running in background.
Also, you can avoid 30 paise cutting by maintaining balance below 30 paise.

You will require to have winrar to get Airtel free GPRS Browser software. Download Winzix here.
So friends, this Airtel hack to get free Airtel gprs will surely work for you. I have personally tried this out in Maharashtra and found it working to get Airtel free gprs. If you find this working, please mention “Your State” in comments so that other Airtel subscribers of your state may also be benefitted. If you have any problem in using this trick to hack Airtel for Airtel free gprs, please mention it in comments.

Enjoy n hack Airtel for Airtel free GPRS…

AIRTEL SONG IN C

Airtel song in c
#include
#include
float main(void)
{
float A,Bb,D,G,F;
A = 440;
G = 780;
Bb = 461;
D = 586;
F = 687;
sound(G);
delay(500);
nosound();
sound(G);
delay(250);
nosound();
sound(G);
delay(250);
nosound();
sound(G);
delay(500);
nosound();
sound(2*D);
delay(500);
nosound();
sound(2*A);
delay(250);
nosound();
sound(2*Bb);
delay(250);
nosound();
sound(2*A);
delay(250);
nosound();
sound(G);
delay(250);
nosound();
sound(F);
delay(500);
nosound();
sound(2*A);
delay(500);
nosound();
sound(G);
delay(250);
nosound();
sound(2*A);
delay(250);
nosound();
sound(G);
delay(250);
nosound();
sound(F);
delay(250);
sound(G);
delay(250);
sound(2*A);
delay(250);
sound(2*Bb);
delay(500);
sound(2*A);
delay(500);
sound(G);
delay(250);
sound(F);
delay(250);
sound(D);
delay(500);
nosound();



//end 1
sound(G);
delay(500);
nosound();
sound(G);
delay(250);
nosound();
sound(G);
delay(250);
nosound();
sound(G);
delay(500);
nosound();
sound(2*D);
delay(500);
nosound();
sound(2*A);
delay(250);
nosound();
sound(2*Bb);
delay(250);
nosound();
sound(2*A);
delay(250);
nosound();
sound(G);
delay(250);
nosound();
sound(F);
delay(500);
nosound();
sound(2*A);
delay(500);
nosound();
sound(G);
delay(250);
nosound();
sound(2*A);
delay(250);
nosound();
sound(G);
delay(250);
nosound();
sound(F);
delay(250);
sound(G);
delay(250);
sound(2*A);
delay(250);
sound(2*Bb);
delay(500);
sound(2*A);
delay(500);
sound(G);
delay(250);
sound(F);
delay(250);
sound(D);
delay(500);
nosound();
//end 2
sound(2*A);
delay(250);
nosound();
sound(G);
delay(250);
nosound();
sound(F);
delay(250);
sound(G);
delay(250);
sound(2*A);
delay(250);
sound(2*Bb);
delay(500);
sound(2*A);
delay(500);
sound(G);
delay(250);
sound(F);
delay(250);
sound(D);
delay(500);
nosound();
//end 3
sound(2*A);
delay(250);
nosound();
sound(G);
delay(250);
nosound();
sound(F);
delay(250);
sound(G);
delay(250);
sound(2*A);
delay(250);
sound(2*Bb);
delay(500);
sound(2*A);
delay(500);
sound(G);
delay(250);
sound(F);
delay(250);
sound(D);
delay(500);
nosound();
return 0;
}



*********************************


Run Whole command In ur pc and u here the song of Airtel ...... in C


**********************************

Sunday, November 8, 2009

Hacking Class 2 - Footprinting and How It can be HelpFul to Hack systems

Previously We have Introduces hacking and hackers. Now In this class we will see what hackers do in pre-phases of hacking .i.e Foot printing.




What Is FOOTPRINTING ??
Basically footprint is the blueprints of site/organisation/system that a hacker want to Hack i.e basic internal structure.Footprinting is the blueprint of the security profile of an organization, undertaken in a methodological
manner.


Footprinting is one of the three pre-attack phases. The others are scanning and enumeration.


Important Thing to be Noted : An attacker will spend 90% of the time in profiling an organization and another 10% in launching the attack.


Now What is the result of Footprinting??? Can anyone guess It.... I explain it..




Footprinting results in a unique organization profile with respect to networks (Internet/intranet/extranet /wireless) and systems involved.Don't It look amazing...


The most interesting stage of a targeted attack is the reconnaissance, or footprint analysis. Here you use the web, search engines, whois.com, to discover as much about the target as possible. A whois.com can tell you email address formats for instance (first letter last name @ company.com).
A Google search could reveal submission to forums by security personnel that reveal brands of firewall or antivirus in use at the target.
Sometimes network diagrams are even found that can guide an attack. The next stage, scanning, meant using special tools, ( I date myself by mentioning Cybercop and Internet Security Scanner, these were the days before the open source Nessus) to discover open ports, services, and machines on the target network. And then, finally, you could start attacking various vulnerabilities that you had discovered.




SITES THAT HELP IN FOOTPRINTING!
1. www.whois.domaintools.com
Now How It can Help You To GET Info . I will Show It Through Snapshots...






2. Now you can use this information to search more about Person using Simply google as shown in next snapshot..






Now Its on you need How much info u want to explore about the person and website which u want to hack...


I think you all Will Like Thisss.... WE will continue Our Discussion on FOOTPRINTING tomorrow also... As It is the Most Important Phase.....
We will Explore More Information in the Next class.... I will explain Few More interesting facts and information exploring things so read on...




I think this Deserves For Comments...Comments Please!

Friday, November 6, 2009

SQL INJECTION HACK ANY WEBSITE ONLY FOR EDUCATIONAL PURPOSE

text describing the image

SQL INJECTION ONLY FOR EDUCATIONAL PURPOSE PLEASE DON'T MISS USE IT WE ARE NOT RESPONSIBLE FOR ANY TYPE OF MISS USE OF THIS SOFT WARE

10 MOST IMPORTANT SECURITY TIPS

text describing the image

10 MOST IMPORTANT SECURITY TIPS TO ENHANCE YOUR PC SECURITY BY DARK MASTER TESTED

FIRST HACKING TUTORIAL ONLY FOR EDUCATIONAL PURPOSE

This is the Very First Tutorial Of Hacking . In this tutorial we will discuss what is hacking.. ethical hacking security...who are hackers...why we do hacking...and Introduction to some basic terms...First of all I will try Explain what the Hacking really is....


What Is Hacking??

Everyone Here thinks that hacking is just stealing of data and information illegally but this perception is absolutely wrong. The below is definition from Wikipedia.... Itz clearly showing hacking as a negative thing..."Hacking is unauthorized use of computer and network resources. (The term "hacker" originally meant a very gifted programmer. In recent years though, with easier access to multiple systems, it now has negative implications.)"Hacking is not always unauthorized... Hacking also include Exploring the Things that are being Hidden from the general usage... So exploring things i.e being Hidden from general User is also hacking...Hacking Definition by Me..." Hacking is art of exploring the hidden things that are being hidden from general usage and finding loop holes in the security and use them to benefit the others"


WHO ARE HACKERS ??


Everybody here thinks thats hackers are criminals of the virtual world (i.e digital World ). But this thought is also wrong. Hackers are not always criminals.. It doesn't have any doubt that Hackers are extremely genious peoples in the field of Computers...I want to Categorize hackers in three Categories:1. Crackers or Black Hat hackers or cheaters or simply criminals : They are called criminals because they are having the mindset of causing harm to security and they steals very useful data and use it in wrong ways. Phishers also some in this category who steals account info and steal your credit card nos. and money over the Net.2. Ethical hackers : Ethical Hacking Means you think like Hackers. i.e First you Hack the Systems and find out the loop holes and then try to correct those Loop Holes..These type of hackers protect the cyberworld from every possible threat and fixes the future coming security loop holes. These peoples are also called as "GURU's" of Computer

Security.3. Simply Prankers : The hackers who just do hacking for fun...play pranks to their friends..

text describing the image
INTRODUCTION TO SIMPLE TERMS RELATED TO HACKING !
Threat –An action or event that might compromise security. A threat is a potential violation ofsecurity.
Vulnerability –Existence of a weakness, design, or implementation error that can lead to an unexpected, undesirable event compromising the security of the system.
Exploit –A defined way to breach the security of an system through vulnerability. i.e Use the vulnerability to damage the database or system.
Attack –An assault on system security that derives from an intelligent threat. An attack is any action that violates security.
Target of Evaluation –An IT system, product, or component that is identified/subjected as requiring security evaluation.
Security – A state of well-being of information and infrastructures in which the possibility of successful yet undetected theft, tampering, and disruption of information and services is kept low or tolerable.
Security rests on confidentiality, authenticity, integrity, and availability.•Confidentiality –The concealment of information or resources.•Authenticity –The identification and assurance of the origin of information.•Integrity –The trustworthiness of data or resources in terms of preventing improper and unauthorized changes.•Availability –The ability to use the information or resource desired.INTRODUCTION TO TOPICS THAT WE COVER IN THESE CLASSES !
I tYou all would have like this and want to see more.. I will regularly post material.I think this deserves Comments and facts that Users want's to ask about Hacking... So Don't hesitate and ask your queries . I am there to reply them all...Have Fun and Keep Learning.... As Hacking is the art of expertising Computers...hink

C AND C++ COMPILER

text describing the image

C AND C++ COMPILER DOWNLOAD FROM HERE..

Thursday, November 5, 2009

TROJAN

A Trojan horse is an unauthorized program contained within a legitimate program. This unauthorized program performs functions unknown (and probably unwanted) by the user.

* It is a legitimate program that has been altered by the placement of unauthorized
* code within it; this code performs functions unknown (and probably unwanted) by the user.
* Any program that appears to perform a desirable and necessary function but that (because of unauthorized code within it that is unknown to the user) performs functions unknown (and definitely unwanted) by the user.


Working of Trojans







* Attacker gets access to the trojaned system as the system goes online
* By way of the access provided by the trojan attacker can stage attacks of different types.

Various Trojan Types

* Remote Access Trojans
* Password Sending Trojans
* Keyloggers
* Destructive
* Denial Of Service (DoS) Attack Trojans
* Proxy/Wingate Trojans
* FTP Trojans
* Software Detection Killers

Modes of Transmission

* Attachments
* Physical Access
* Browser And E-mail Software Bugs
* NetBIOS (File Sharing)
* Fake Programs
* Un-trusted Sites And Freeware Software

Backdoor Countermeasures

* Most commercial ant-virus products can automatically scan and detect backdoor programs before they can cause damage (Eg. before accessing a floppy, running exe or downloading mail)
* An inexpensive tool called Cleaner TROJAN REMOVER can identify and eradicate all types of backdoor programs and trojans.
* Educate your users not to install applications downloaded from the internet and e-mail attachments.
Modifying temporaries
Temporary objects are created and destroyed all the time in a C++ program. A simple example would be a function that returns by value. A temporary is as good as a const object because it makes little sense (usually) to change a temporary object, which is unnamed and has a very short time span. (Note: A temporary can be bound to a const reference in which case the scope of the temporary is the same as that of the reference.) However, as it turns out, in C++ you can change temporaries ... if they are of class type! You can call non-const member functions on a temporary. This is quite similar to binding a temporary to a non-const reference and changing it. Section 3.10.10 in C++ ISO/IEC 14882:1998 standard clearly mentions this exception. There are at least two practical use of such an exception. One is the "Named Parameter" idiom and the other one is the Move Constructor idiom. In case of the named parameter idiom, the member functions might prefer to return the object by non-const reference instead of a by value. Here is an example:

class X
{
public:
int a;
char b;
X() : a(0), b(0) {}
X setA(int i) { a = i; return *this; } // non-const function
X setB(char c) { b = c; return *this; } // non-const function
};

std::ostream & operator << (std::ostream & o, X const & x)
{
o << x.a << " " << x.b;
return o;
}

X createX() // returns X by value.
{
return X();
}

int main (void)
{
// The following code uses the named parameter idiom.
std::cout << createX().setA(10).setB('Z') << std::endl;
}

pointer pitfall

pointer pitfall

Some C pointer fundamentals manage to fox even seasoned programmers.
For example, what is wrong with the following piece of code:

func() {

char *c;
c = "this is a string.";
*c = 'T';
printf("%s", c);
}


The code tries to capitalize the first letter of the string. It looks correct at first glance, but is not. It might even compile without any error, but will throw out an error when run.

PROGARMING BY GAURAV GARG

ASK YOUR QUESTIONS


Your Name
Your Email Address
Subject
Message
SEND YOUR IDEAS
Image Verification
captcha
Please enter the text from the image:
[ Refresh Image ] [ What's This? ]

 
Home | About Owner | Tutorials | Freebies | About Us | Contact Us

Copyright © 2009 CYBERWORLD |Designed by 13551421 143 Templetemo |Converted to blogger by Dark Master