Saturday, March 5, 2011

UNIX FOR DOS ADDICTED WaReZ PuPPieZ AND THEIR PETS




 
  Introduction
  ------------

  One of the most common operating systems in existance is Unix. Unix
  exists in many different flavors, from Berkeley BSD to AT&T System V
  to SunOs. Basic working knowledge of Unix is almost essential to a
  hacker, as it is the system a hacker is most likely to come across.
  If you intend to use the internet at all, or to do any serious
  exploration of Telenet, the ability to navigate through Unix is a
  necessity. (Unix is also the single most interesting system in
  existance: ).

  Unix Logins
  -----------

  Most Unix logins look essentially the same. A general Unix login
  prompt looks something like this:

  connected to five.finger.com
  login:

  That first line is the system identifier. Although it's not at all
  essential to what you are doing, it's good to know what system you are
  attempting to log on to.
  The second line is what typically identifies the system you are on as
  Unix. Almost all Unix systems greet a user with the same prompt:
  login:.
  Well, there's not much to do in Unix from the outside, and Unix
  systems are typically fairly secure at this point. You may be able to
  obtain a list of users, or current users, by logging in as 'who', but
  other than that there are few functions available here.
  Unless you are on the internet, or have accounts specifically for the
  specific machine you are on, the only way on to the system is to try
  the default passwords. What are the default passwords?
  Unix systems come installed with certain passwords automatically. In
  addition, some accounts must exist on a system. One such account is
  'root'. This user is the divine Kami of the Unix system... in short,
  an all access pass. Unfortunately, few systems allow root logins
  remotely, and even fewer leave 'root' unpassworded. Nevertheless, it's
  always worth a shot... try this:

  connected to ren.stimpy.net
  login: root
  password: root
  invalid login
  login:

  well, nice try anyways... other possible passwords for root include
  'sysadmin', 'sys', 'admin'... you get the idea. You may also want to
  try these passwords with a single digit appended (added, idiot) to
  them... meaning the password 'root' could be 'root1' or 'root2'.
  An interesting tip about passwords in general... many people that use
  passwords under 8 characters tend to add a digit or a non-alphanumeric
  character to the password. This is done in order to hinder guessing,
  and to stop password breakers (more on this later). In this case, you
  may want to try adding a space before root... or even an ascii 255 to
  the end.
  Fortunately, there is more than one default password in a unix
  system... a quick list:

  sys        sys
  bin        bin
  daemon     daemon
  rje        rje
  setup      setup
  uucp       uucp/nuucp/anonymous
  nuucp      uucp/nuucp/anonymous
  mountfsys  mountfsys

  In the System
  -------------

  Ok, at this point, I'm going to assume you've gotten past the login...
  as painful as that may sound. Although Unix may be secure from the
  outside, without effort from the system administrators, the inside of
  the system is not.
  First off, you'll likely by asked for a terminal. vt100 serves your
  purposes sufficently, and it's typically the default, so hit enter.
  Now, hopefully, you have a prompt. There are many different types of
  unix prompts, some of which contain current directory information,
  some of which are just a single character. Just don't panic when my
  examples don't look exactly like what you've got on your screen.
  The first thing you *need* to do on the system is establish your tty
  paramters. As eldritch and arcane sounding as this term may seem, it's
  actually quite simple... you need to tell the system what keys are
  going to do what.
  The command to set these parameters is 'stty'. Watch:

  squinkyB ] stty erase ^h
  squinkyB ]

  There... that wasn't so bad, was it? Well, it's also pretty
  meaningless to you, unless you have the ascii table memorized and are
  pretty good at on-the-spot deduction.
  The tty erase parameters determines which key is to be used as a
  backspace. At times, this may already be set when you log in, or it
  may be set to a suitable alternate (such as delete). Most of the time
  the system will tell you when you log on if this is so. In this case,
  we've entered ^h in order to make the backspace key, appropriately
  enough, backspace.
  Another extremely important parameter is 'intr'. The 'intr' paramter
  tells the Unix system what you intend to use as a break character...
  you should have this set to ^c.



  Getting Around
  --------------

  A good thing to remember about Unix is that it's alot like DOS. Files
  are laid out in directories just as in DOS... in fact, the only
  immediate difference in the directory structures is that Unix uses a
  forward slash ("/", moron!) instead of a backwards one.
  Also, the basic Unix directory navigation command is identical to DOS.
  In order to change directories, you use the command 'chdir', or 'cd'.
  A quick example:

  1 /usr1/astoria ] cd ..
  2 /usr ]

  Wala. That simple. Quick notes:

  ю cd / will take you to root.
  ю cd /*pathname* will take you to *pathname*
  ю cd home will take you to your home directory.

  You can make and delete your own directories with the mkdir/rmdir
  commands. Simply put, mkdir makes a subdirectory off of the current
  directory, and rmdir removes a subdirectory from the current
  subdirectory. Good to know if you plan to do a lot of file transfers.
  An important note about Unix directories, files, and concepts:
  Unix is a case-sensitive operating system. Thus, the files

  ю Spleen
  ю spleen
  ю SPLEEN
  ю SpLeEn

  are all different. This rule applies to directories and command line
  paramters, as well as most other Unix ideas.
  Another nice thing to know about Unix: Unix files are not subject to
  the normal DOS 8 character limit. Thus, you can have vast filenames,
  such as "this_file_ate_my_biscuit".

  Some other important commands
  -----------------------------

  First and foremost, you should know cp. cp is the basic Unix
  equivalent of the DOS COPY command. The command line for cp is
  identical to that of COPY.
  Next on the scale of cosmic import is cat. cat is the Unix equivalent
  of the DOS TYPE command, and once again, for simple file displaying,
  the command line is identical.
   Variations on the theme:
   pg: displayes a file page by page. Type "pg x filename", where x is a
       number of lines to display before pausing and filename is the
       file you wish to display.
   more: displays a file screen by screen.
   Stupid pet trick:
   You can use your cat to copy files, simply by using the directional
   operators. To copy a file from here to there using cat, simply type:

   % cat here
   this is the file here
   % cat there
   this is the file there
   % cat here > there
   % cat there
   this is the file here

   The operator ">" simply takes the output from the cat command and
   places is in the location specified after it.
  Another vital command to know is 'rm'. rm deletes a file from the
  system, in the same way DEL would on a DOS system. Not to much else to
  say.
  Critical in your navigation of a Unix system is the ls command. ls is
  DOS DIR on heroin. Simply type ls and you get a nice, neat list of
  files in the directory.
   DIR on controlled substances:
   There are a few command line parameters that you should know...
   foremost is l. ls -l gets you a list of files, and valuable
   information about each file, including permissions (more on that
   later), size, and linked files.
   Another useful command for long file lists is C. ls -C gets you a
   list of files in multiple columns, much the same as DIR /W would
   merit a double column report of all existing files. A quick reminder:
   ls -C is NOT the same as ls -c. Unix = case sensitive.
  Another good command to know, mv will move a file from directory to
  directory. For those of you without DOS 6.0 <gasp>, mv simply copies a
  file to another directory and deletes the original.
   quick tip for files on the lam:
   if you want to rename a file (to protect the innocent), you need to
   mv a file to a different file name. A quick demo:

   # ls
   myfile
   # cat myfile
   this is my file
   # mv myfile my_other_file
   # ls
   my_other_file
   # cat my_other_file
   this is my file

  Another vastly important command is 'man'. In fact, man is probably
  one of the most important commands extant for a beginning user... it
  calls up the system's help files. To use man, simply type in 'man
  command', where command is a Unix command you seek to gain
  enlightenment regarding. It's a great way to gain an understanding of
  Unix commandline parameters.

  If you are interested in seeing who's been on of late, or just want a
  few names to try to hack, type 'who'. You get a quick list of users
  that have accessed the system lately. If you <god forbid> need to know
  who you are at this point, type 'whoami'.

  If you want to change your identity on the system, type 'su name'
  where name is an account on the system. It'll ask you for the account
  password, then, *presto*... instant transmogrification.



   A Caveat for smart alec hackers:

   Unix typically logs usage of the su command. While su may seem like a
   great opportunity to try to hack out passwords manually without
   worrying about the system hanging up after 3 attempts, it's typically
   not a good idea to do this, as it may alert the administrators to
   your presence.

  *Numero Uno on the list of commands NEVER to use on a Unix system:

  The 'passwd' command changes your password on a Unix system. Seems
  innocous enough, eh? Uh-uh. If your account is active, and there's a
  very strong chance that it either is or will be, there is no better
  way to lose the account than to change the password, only to have the
  legitimate user alert the sysadmins when he/she can't gain access to
  his/her normal account (well, there are better ways... you could
  simply mail the sysadmin and tell him you are trying to hack his
  grandmother's life support machine through your account).
  I've seen this single, quick command turn a extremely lax system
  into an ironclad security compound in less than a day.

  DONT-MISUSE-WITH-IT.

  *Numero Dos on that same list:

  The 'mail' command reads and sends mail. So what? Well, unless your
  account is stable (and it isn't unless you either paid for it or
  killed the original owner in such a way that his body cannot claw it's
  way out of it's grave to it's keyboard), the user is more likely than
  not going to know if you read his mail. In addition, if you send mail
  out of the system (type 'mail', and a username/address; type in your
  message and end it with a ^d on it's own line), the response from your
  message will likewise alert the user to your presence.

  System Spelunking
  -----------------

  The first place you want to check out in the wild uncharted directory
  tree of your friendly neighborhood Unix system is the "/etc"
  directory. What's in it? The single most intensely important file on
  the system (besides a world writable root owned SUID file... but don't
  worry about that)... the passwd file.
  What is in the passwd file?

  ю  a list of all accounts on the system
  ю  a list of the passwords for these accounts
  ю  a list of access levels for these accounts
  ю  a list of the home directories for these accounts
  ю  a list of information pertaining to these accounts.

  Why the hell the Unix designers decided this file should be world
  readable is beyond me. Be content to know that your standard everyday
  run-of-the-mill-lacking-in-certified-cosmic-power 'cat' command WILL
  display this file. As will pg and more. However, because most users
  don't have write permissions (more on that later) to the /etc
  directory, 'cat' is pretty much the only applicable command here.
  However, if you need to copy the file to your own directory (for
  whatever reason), just cat it there with the directional operator (>).

  The catch:

  Well, there are two catches here. First off, regardless of system
  security, if the passwords are in the file, they are encrypted. You
  can't decrypt them. Although you can get a list of accounts without
  passwords this way (just look for accounts with no entry in the
  password field), and a list of accounts that can't be logged onto
  remotely/at all (NO LOGIN), you can't get much else. Sucks, don't it?
  Notice I said 'if' the passwords are there.

  <ominous soundtrack please>

  Some horrible, paranoid, draconian system administrators mutilate
  their passwd files in such a way that (*gasp*) the passwords don't
  show up. All you get is one cold, icy X staring at you from the bowels
  of Unix Shell Siberia, mocking you as you pull your hair out in
  frustration (sorry, but this is a sore spot with me). The kidnapped
  passwords reside in the shadow file in the /etc directory, available
  with your standard everyday run-of-the-mill-but-distinct-in-the-fact-
  that-only-root-level-accounts-can-use-it-to-this-extent 'cat' command.
  Well, if the passwords are encrypted, what good are they?

  By themselves, nothing. A account with a Unix encrypted password will
  get you no further than an account with no listed password at all. You
  can't even deduce the amount of characters in the password if it's
  encrypted. So what's the use?

  The Unix method of encrypting files is available to the public. It is
  also, to most mortals, irreversable. Essentially, this means you can
  encrypt a string of characters, but not decrypt it. Even the unix
  system itself doesn't decrypt the password when you log on...
  When you log on, the Unix system takes whatever you enter at the
  password prompt, encrypts it, and matches it to the entry in the
  passwd file. Thus, the Unix system never decrypts the password... it
  only compares it to a different encrypted string.



  While this may not sound too particularly useful at first, it is.
  There are programs that have been written to do the same thing on a
  personal computer... you supply it a list of passwords and a list of
  words to attempt to use as passwords (called dictionaries), and it
  spends the night encrypting dictionaries and matching them to password
  entries. By running a dictionary through a passwd file, on a typical
  system, you can usually get 10-20 accounts. Good personal computer
  examples of this program idea include Killer Cracker (the industry
  standard, so to speak) and CrackerJack (faster than Killer Cracker).
   Quick tips for CrackerJunkies with leech access at an H/P BBS:
   A standard dictionary will not uncover passwords protected with an
   appended digit or non-alphanumeric character. In order to get around
   this, you need only grab a program that processes the dictionary file
   to add that digit to each entry in the dictionary... although this
   takes longer, and you'll need to do it multiple times, you can
   typically get 10 more accounts just by adding a 1 to every entry.
  Files and directories in Unix are characterized further by their
  permissions. Permissions are a standard system of who gets access to a
  specific function of that file or directory. Standard permissions
  include read, write, and execute. You can get a list of permissions by
  typing 'ls -l'. The first field in the listing contains the
  permissions, grouped as follows:

  owner  group   world
  --------------------
  rwx    rwx     rwx

  (Not drawn to scale... in fact, it doesn't look anything like that).
  Essentially, as long as the letter is there, you have access to that
  facet of the file. If the letter is not there, you'll see a dash...
  meaning you don't have access to that function. An example:

  rwxr-x--x

  In this case, the owner of the file can Read the file, Write to the
  file, and eXecute the file; members of his group (a bunch of linked
  accounts) can Read the file, CANNOT Write to the file, and can eXecute
  the file; and the rest of the user population CANNOT Read or Write to
  the file, but CAN eXecute the file.

  rwx---rwx

  is a WORLD-READABLE, WORLD-WRITABLE, WORLD-EXECUTABLE file. This
  simply means that anyone can read, write, or execute the file.

  Another permission sometimes set to a file is the SUID bit. An SUID
  file contains a smallcase s in the user executable section of the
  permissions list...

  rws--x--x

  When you execute an SUID file, your user ID becomes that of the owner
  of the file. While this may not look to important at first, by now you
  should know that no really important super elite hacker concept does.
  Take a look at this:

  rwsr-x--x

  Synopsis? It's a world executable SUID file. In essence, anyone can
  execute the file, and in doing so, become the owner of the file for
  the duration of the time that file is operating. However, this doesn't
  get you much, because you typically can't do anything while the
  programis running. More likely than not, it's calculating how many
  pencils it needs to order for school tomorrow or some other such
  drivel.
  The real power of the SUID file comes into play in this situation:

  rwsrwxrwx

  You won't see a lot of these, but when you do, look out. What you have
  here is a world writable SUID file... and a world writable program can
  be any program on the system you have read access to. Like, say,
  /bin/sh... the Unix shell...
  Quick command line example... 'diablo' is a root owned, world writable
  SUID file. I'm going to ignore the rest of the output of the ls
  command.

  #ls -l
  rwsrwxrwx... ...diablo
  #cat /bin/sh > diablo
  #diablo
  $

  Oh, just so you know, the $ prompt denotes root access.
  Good deal, huh? In general, if you have right privs to an SUID file,
  copy it to your own directory and cat /bin/sh into it. You now have an
  instant gateway to the account of the owner of that file.
  If you want to find files that you can do this with, try this out:

  #find / -user root -perm -4000 -exec /bin/ls -al {} ";"

  This will give you a list of all root owned SUID files. If you want
  more info on the 'find' command, just 'man find'.

Thursday, March 3, 2011

Anonymity complete GUIDE


Anonymity on the web



[ t a b l e o f c o n t e n t s ]
01 - table of contents
02 - introduction
03 - first tips
04 - about proxies
05 - cookies
06 - ftp transfers
07 - secure transactions
08 - SSL tunelling
09 - anonymity on irc
10 - mail crypto (and pgp usage)
11 - icq privacy
12 - spyware
13 - cleaning tracks
14 - ending words

[ introduction ]
Nowadays, everyone wants privacy on the web, because no matter where you go, someone could be watching you. Someone like your employer, someone trying to hack your system, companies gathering all your info to sell to yet other companies, or even the government, may be on your track while you peacefully surf the web. Thus, anonymity on the web means being able tu use all of its services with no concern about someone snooping on your data.
Your computer being connected to the net has an IP [Internet Protocol] address. If you have a dial-up connection, then your IP changes every time you connect to the internet (this is not always true, though. There are dialup isps, specially for university students, that do have static ips). Cable modems and DSL connections have a static IP, which means that the IP address does not change. One of the goals of getting anonymous is to make sure your ip, either static or dynamic) isn't revealed to other users of the internet, or to server administrators of the servers you roam around when using internet services.
This text tries to give you some hints on how to maintain your anonimity on the web. Some of the hints may sound banal, but think of, if you really abide them in every situation.

[ first tips ]
When chatting on IRC, ICQ, AIM (etc..), do not give out personal information about yourself, where you live, work, etc.
Do not use your primary email address (the one your ISP gave you) anywhere except to family members, close friends or trusted people. Instead create for yourself a web-based email account such as yahoo, hotmail, dynamitemail, mail.com, etc. and use this e-mail address to signing up for services, when in the need to give your mail to download something, or to publish on your homepage.
When signing up for services on the web, don't give your real information like address, phone number and such unless you really need to do so. This is the kind of information that information gathering companies like to get, so that they can sell out and fill your mailbox with spam.
Use an anonymous proxy to surf the web. This makes sure your ip doesn't get stored on the webserver logs. (Webservers log every GET request made, together with date, hour, and IP. This is where the proxy comes in. They get the ip from the proxy, not yours)
Use a bouncer to connect to IRC networks, in case you don't trust the administrators, or the other users. A bouncer is a program that sits on a permanently connected machine that allows you to connect there, and from there to the irc server, just like a proxy works for webservers.
Use anonymous remailers to send out your e-mails.
Cryptography can also help you by making sure the material you send out the web, like by email, etc, is cyphered, not allowing anyone that doesn't have your key to read it (in key-based cryptography). Programs like PGP (pretty good privacy) are toolkits with all you need to cypher and uncypher your stuff.
Delete traces of your work with the computer including history files, cache or backup files. 


[ about proxies ]
Proxies are caches that relay data. When you configure your web browser to use a proxy, it never connects to the URL. Instead it always connects to the proxy server, and asks it to get the URL for you. It works similarly with other type of services such as IRC, ICQ etc. There'll won't be direct connection between you and the server, so your real IP address won't be revealed to the server. When you view a website on the server, the server won't see your IP. Some of web proxies do not support forwarding of the cookies whose support is required by some of the websites (for ex. Hotmail).
Here are some anonymous proxies that you can use to surf anonymously (notice that some of these may be a payed service):
Aixs - http://aixs.net/
Rewebber - http://www.anon.de/
Anonymizer - http://www.anonymizer.com/
The Cloak - http://www.the-cloak.com/
You'll highly probably find many websites that provide the lists of unauthorised proxies and remailers . Such lists are being compiled usually with the help of port scanners or exploit scanners, scanning for computers with wingate or other proxies' backdoors. Using these proxies is illegal, and is being considered as unauthorized access of computer. If you get such list to your hands, check if the info is legal or compiled by script kiddie, and act acordingly.
If you anyhow decide not to use proxy, at least do not forget to remove your personal information from your browser. After you remove details like your name and e-mail address from your browser, the only info a Web site can sniff out is your ISP's address and geographical location. Also Java and JavaScript applets can take control of your browser unexpectedly, and if you are surfing to unknown and potentially dangerous places you should be aware of that. There are exploitable browser bugs (mainly Internet explorer ones) reported ever week. 



[ cookies ]
Maybe you're not aware of the fact that if you have the "allow cookies" feature in your browser on, websites can store all sorts of information on your harddrive. Cookies are small files that contain various kind of information that can be read bt websites when you visit them. The usual usage is to track demographics for advertising agencies that want to see just what kinds of consumers a certain site is attracting. Web sites also use cookies to keep your account information up-to-date. Then for instance when you visit your e-mail webbased account without being unlogged some hours later, you find yourself being logged on, even if you turn off your computer. Your login and password was simply stored on your harddrive in cookie file. This is security threat, in case that there is more persons who have the access to your computer.
Most of the browsers offer the possiblity to turn off the cookies, but some of sites like Hotmail.com require them to be turned on. In case you decided to allow cookies, at least never forget to log off from the websites when you're finishing visiting them. 



[ ftp transfers ]
When using an FTP client program to download files, assure yourself, that it's giving a bogus password, like guest@unknown.com, not your real one. If your browser lets you, turn off the feature that sends your e-mail address as a password for anonymous FTP sessions.

[ secure transaction ]
Everything being sent from the web server to your browser is usually in plain text format. That means, all transferred information can be easily sniffed on the route. Some of the web servers support SSL (which stands for Secure Socket Layer). To view and use these websites you'll need SSL support in your browser as well. You recognize, that the connection is encrypted, if URL starts with https:// instead of usual http://. Never use web server without SSL for sending or receiving sensitive private or business information (credit card numbers, passwords etc.)

[ SSL tunelling ]
What is SSL?
SSL stands for Secure Socket Layer. The ?Secure? implies an encryption, while Socket Layer denotes an addition to the Window Socket system, Winsock. For those that don?t know, a Socket is an attachment to a port on a system. You can have many sockets on one port, providing they are non-blocking (allowing control to pass through to another socket aware application which wishes to connect to that port).
A Secure Socket Layer means that any sockets under it, are both secure and safe. The idea behind SSL was to provide an encrypted, and thus, secure route for traffic along a socket based system, such as TCP/IP (the internet protocol). Doing this allows security in credit card transactions on the Internet, encrypted and protected communiqué along a data line, and overall peace of mind.
The SSL uses an encryption standard developed by RSA. RSA are a world respected American organisation that specializes in encryption and data security. Initially, they developed a cipher length of only 40 bits, for use with the Secure Socket Layer, this was considered weak and therefore a longer much more complicated encryption cipher was created, 128 bits. The reasoning behind it was simple: it needs to be secure.
The RSA site puts the advantage of a longer encryption length pretty clearly: because 40-bit encryption is considered to be relatively weak. 128-bits is about 309 septillion times ( 309,485,000,000,000,000,000,000,000 ) larger than 40-bits. This would mean it would take that many times longer to crack or break 128-bit encryption than it would 40-bit.
If you want more information on the technicalities or RSA?s SSL encryption engine, visit their site: http://www.rsasecurity.com/standards/ssl.

 SSL uses public key encryption as explained in the PGP section.
And how do I implement SSL with SSL Tunnelling?
We know that a Secure Socket Layer is safe, but what we don?t know is what a Tunnel is. In the most simplistic form, a tunnel is a proxy. Like proxy voting in general elections, a tunnel will relay your data back and forth for you. You may be aware though, that there are already ?proxies? out there, and yes, that is true. Tunnelling is done via proxies, but it is not considered to be the same as a standard proxy relaying simply because it isn?t.
Tunnelling is very special kind of proxy relay, in that it can, and does relay data without interfering. It does this transparently and without grievance or any care for what is passing its way.
Now, if we add this ability to ?tunnel? data, any data, in a pipe, to the Secure Sockets Layer, we have a closed connection that is independent of the software carrying it; and something that is also encrypted. For those of you wanting to know a little more about the technicalities, the SSL layer is also classless in the sense it does not interferer with the data passed back and forth ? after all, it is encrypted and impossible to tamper with. That attribute means an SSL capable proxy is able to transfer data out of its ?proxied? connection to the destination required.
So to sum up, we have both a secure connection that does the job and relays things in the right direction; and we have direct tunnel that doesn?t care what we pass through it. Two very useful, and almost blind entities. All we need now is a secure proxy that we can use as the tunnel. 


Proxies:

Secure proxies are alike standard proxies. We can either use an HTTP base SSL equipped proxy - one specifically designed for security HTTP traffic, but because of the ignorant nature of SSL communication, it can be bent to any needs ? or we can use a proper SSL service designed for our connection ? like you would use a secure NNTP (news) program with a secure proxy on port 563 instead of taking our long way - which would probably work as well.
A secure HTTP proxy operates on port 443. Host proxies are not public, that means they operate for, and allow only traffic from their subnet or the ISP that operates them ? but, there are many badly configured HTTP proxies and some public ones out there. The use of a program called HTTrack (available on Neworder) will aid you in scanning and searching for proxies on your network or anywhere on the Internet if your ISP does not provide you with one.
Neworder also features a number of sites dedicated to listing public proxies in the Anonymity section. While it?s often hard to find a suitable fast proxy, it?s worth the effort when you get one.
So how can I secure my connections with SSL Tunnelling?
That?s a big question, and beyond the scope out this tuition as it must come to and end. I can however, point you in the right direction of two resources that will aid you in tunnelling both IRC, and most other connections via a HTTP proxy.
For Windows, the first stop would be http://www.totalrc.net?s Socks2HTTP. This is an SSL tunnelling program that turns a normal socks proxy connection into a tunnelled SSL connection.
The second stop, for both Windows and Unix is stunnel. Stunnel is a GNU kit developed for SSL tunnelling any connection. It is available for compile and download as binary here: Stunnel homepage - http://mike.daewoo.com.pl/computer/stunnel 



[ anonymity on irc ]
A BNC, or a Bouncer - is used in conjunction with IRC as a way of hiding your host when people /whois you. On most IRC networks, your host isnt masked when you whois, meaning the entire IP appears, like 194.2.0.21, which can be resolved. On other networks, your host might be masked, like IRCnetwork-0.1 but it can still give valuable information, like nationality if your host is not a IP, but a DNS resolved host, like my.host.cn would be masked to IRCnetwork-host.cn but this would still tell the person who whoised you, that you are from China.
To keep information such as this hidden from the other users on an IRC network, many people use a Bouncer, which is actually just a Proxy. Let us first draw a schematic of how a normal connection would look, with and without a BNC installed.
Without a BNC:
your.host.cn <<-->> irc.box.sk
With a BNC:
your.host.cn <<-->> my.shell.com <<-->> irc.box.sk
You will notice the difference between the two. When you have a BNC installed, a shell functions as a link between you and the IRC server (irc.box.sk as an example). You install a BNC on a shell, and set a port for it to listen for connections on. You then login to the shell with your IRC client, BitchX/Xchat/mIRC, and then it will login to the IRC server you specify - irc.box.sk in this case. In affect, this changes your host, in that it is my.shell.com that makes all the requests to irc.box.sk, and irc.box.sk doesn't know of your.host.cn, it has never even made contact with it.
In that way, depending on what host your shell has, you can login to IRC with a host like i.rule.com, these vhosts are then actually just an alias for your own machine, your.host.cn, and it is all completely transparent to the IRC server.
Many servers have sock bots that check for socket connections. These aren't BNC connections, and BNC cannot be tested using a simple bot, unless your shell has a socket port open (normally 1080) it will let you in with no problem at all, the shell is not acting as a proxy like you would expect, but more as a simple IRC proxy, or an IRC router. In one way, the BNC just changes the packet and sends it on, like:
to: my.shell.com -> to: irc.box.sk -> to: my.shell.com from: your.host.cn <- from: my.shell.com <- from: irc.box.sk
The BNC simply swaps the host of your packet, saying it comes from my.shell.com. But also be aware, that your own machine is perfectly aware that it has a connection established with my.shell.com, and that YOU know that you are connected to irc.box.sk. Some BNCs are used in IRC networks, to simulate one host. If you had a global IRC network, all linked together, you could have a local server called: cn.myircnetwork.com which Chinese users would log into. It would then Bounce them to the actual network server, in effect making all users from china have the same host - cn.myircnetwork.com, masking their hosts. Of course, you could change the host too - so it didn't reveal the nationality, but it is a nice gesture of some networks, that they mask all hosts from everyone, but it makes life hard for IRCops on the network - but its a small price to pay for privacy.
Note: Even if you do use IRC bouncer, within DCC transfers or chat, your IP will be revealed, because DCC requires direct IP to IP connection. Usual mistake of IRC user is to have DCC auto-reply turned on. For an attacker is then easy to DCC chat you or offer you a file, and when IRC clients are connected, he can find out your IP address in the list of his TCP/IP connections (netstat).
How do I get IRC bouncer?
you download and install bouncer software, or get someone to install it for you (probably the most known and best bouncer available is BNC, homepage : http://gotbnc.com/)
you configure and start the software - in case it's bouncer at Unix machine, you start it on your shell account (let's say shell.somewhere.com)
you open IRC and connect to the bouncer at shell.somewhere.com on the port you told it to start on.
all depending on the setup, you may have to tell it your password and tell it where to connect, and you're now on irc as shell.somewhere.com instead of your regular hostname 


[ mail crypto ]
Usually the safest way to ensure that your e-mail won't be read by unauthorised persons is to encrypt them. To be compatible with the rest of the world I'd suggest to use free PGP software.
PGP (Pretty Good Privacy) is a piece of software, used to ensure that a message/file has not been changed, has not been read, and comes from the person you think it comes from. Download location: http://www.pgpi.org/
How does pgp Work?
The whole idea behind PGP is that of Public and Private keys. To explain the algorithm PGP uses in order to encrypt the message would take too much time, and is beyond the scope of this, we will however look at how it ensures the integrity of the document. A user has a password, this password has to be chosen correctly, so don't choose passwords like "pop" or "iloveyou", this will make an attack more likely to succeed. The password is used to create a private key, and a public key - the algorithm ensures that you can not use the public key to make the private key. The public key is sent to a server, or to the people you send e-mails/files, and you keep the private key secret.
We will use a few terms and people in this introduction, they are: Pk - Public Key, Sk - Secret Key (private key).

[ anonymous remailers ]
Remailers are programs accessible on the Internet that route email and USENET postings anonymously (i.e., the recipient cannot determine who sent the email or posted the article). This way the sender can't be traced back by routing headers included in the e-mail. There are different classes of remailers, which allow anonymous exchange of email and anonymous posting to USENET and often many other useful features.
Resources:
Chain is a menu-driven remailer-chaining script:
http://www.obscura.com/crypto.html
Raph Levien's remailer availability page offers comprehensive information about the subject
http://www.sendfakemail.com/~raph/remailer-list.html
The Cypherpunks Remailers are being developed to provide a secure means of providing anonymity on the nets. Here you can find out about the available remailers, those which have been standard in existance for a long time as well as the new experimental remailers and anonymous servers.
http://www.csua.berkeley.edu/cypherpunks/remailer/

[ icq privacy ]
How can I keep my privacy at ICQ?
Send and receive messages via ICQ server, not directly. Every direct connection enables attacker to learn your IP. Encrypt your messages by dedicated software, encryption addons.
How to encrypt ICQ messages?
There are addons which enhance your ICQ with possibility to encrypt outcoming messages. The user on the other side needs to have the addon as well in order to decrypt your message.
Resources:
http://www.encrsoft.com/products/tsm.html
Top Secret Messenger (TSM) - trial version has only weak 8-bit encryption
http://www.planet-express.com/sven/technical/dev/chatbuddy/default.html
Chat Buddy - a freeware Windows application for encrypting chat sessions
http://www.algonet.se/~henisak/icq/encrypt-v5.txt
how encryption works in ICQ protocol v5

[ spyware ]
As we all work hard to become more savvy about protecting our personal information and keeping as anonymous as possible on the web, advertising companies are working just as hard to come up with new ways of getting our personal information. One of the ways they accomplish this is through spyware.
Spyware are applications that are bundled along with many programs that you download for free. Their function is to gather personal information about you and relay it back to advertising firms. The information is then used either to offer you products or sold to other advertisers, so they can promote THEIR products. They claim this is all they do with this information, but the problem is nobody really knows for sure.
Spyware fits the classic definition of a trojan, as it is something that you did not bargain for+when you agreed to download the product. Not only is spyware an invasion of your privacy, but (especially if you have a few different kinds on your machine) it can also chew up bandwidth, making your internet connection slower.
Sometimes, these spies really are harmless, merely connecting back to the home server to deliver+you more advertising. Some, like Gator for instance, send out detailed information about your surfing habits, operating system, income, age demographic et cetera.
Avoiding spyware
Avoiding spyware is getting harder and harder, as more software distributors are choosing it as a method of profiting from freeware and shareware distributions. Be leery of programs with cute+little icons like Gator. Also, watch those Napster wannabes like AudioGalaxy, Limewire, and Kazaa. I've yet to find one that didn't include spyware. Before you download, check to see if the program is known to contain spyware.
For a list of most known spyware, the best I've found is here:
http://www.infoforce.qc.ca/spyware/enknownlistfrm.html
Getting rid of spyware
In most cases, you can remove the spyware from your system and still use the application you downloaded. In the case of Gator and Comet Cursor, the the whole program is spyware an it must be completely removed to stop the spying.
There are several ways to get rid of spyware on your system. You can use a firewall to monitor outgoing connections. The programmers that put these things together, however, are getting sneakier and sneakier about getting them to circumvent firewalls. Comet Cursor, for instance uses an HTTP post command to connect without the intervention of a firewall. You can also install a registry monitor such as Regmon to monitor your registry for unwanted registry registry changes, but this is not foolproof either.
Probably the best method of removal is to download a spyware removal program and run it like it was a virus scanner. The best examples of these programs are:
Lavasoft's Adaware. Available at http://www.lavasoftusa.com/ Or professional cybernut Steve Gibson's OptOut. Available at: http://grc.com/optout.htm Both of these programs are free and are updated regularly.
Here are some links, if you wish to learn more about spyware:
http://www.spychecker.com/
http://grc.com/optout.htm
http://www.thebee.com/bweb/iinfo200.htm

[ cleaning tracks ]
Resources:
Burnt Cookies - allows automatic detection and optional deletion of Cookies deposited by Banner Ad web-sites
http://www.andersson-design.com/bcookies/index.shtml
Surfsecret - automatically kills files like your Internet cache files, cookies, history, temporary files, recent documents, and the contents of the Recycle Bin.
http://www.surfsecret.com/
Note: One sidenote on cleaning tracks. When you delete some files on your machine, these aren't actually deleted. Only the reference to their location in the hard drive is deleted, which makes the OS think that that location on the HD is free and ready to take things. Thus, there are ways to recover data even after you delete them.
There are however, several ways to _wipe_ this information. Programs that fill hard disk locations with zeros, then with 1s, on several passes are your best bet to make sure no document goes to the wrong hands. One of such programs is PGP. PHPi now comes with a utility that does this work, and you can even select the number of passes to wipe files. For *nix, there is also the "wipe" program. Use these when you feel you have data that needs secure cleaning.

Wednesday, March 2, 2011

How to Create a Virus? --> Video for Beginner



Hi Guys..
                    This a good video for beginners, who wish to create your own virus programs.. This is the basic tutorial for creating Virus using Batch programming...