Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!

Notices

Welcome to LinuxQuestions.org, a friendly and active Linux Community.

You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!

Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.

If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.

Having a problem logging in? Please visit this page to clear all LQ-related cookies.

Introduction to Linux - A Hands on Guide

This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.

Hey
Iptables may be installed by default, but you have to set the rules (ie "computer let me access this port") yourself.

I can't comment on the hacking bit, but I'm sure someone will help you out. In the meantime, I strongly suggest looking to setting up a proper firewall on your server. Your won't need anything difficult.

Iptables may be installed by default, but you have to set the rules (ie "computer let me access this port") yourself.

OK...can someone help me/elaborate on this please...

Quote:

I can't comment on the hacking bit, but I'm sure someone will help you out. In the meantime, I strongly suggest looking to setting up a proper firewall on your server. Your won't need anything difficult.

Regarding firewall, I assume that your computer isn't serving anything to the Internet (ie, you don't run a webserver or anything).

Therefore, you basically just want to allow all request OUT of your box, but not allow any into your box.

If you have iptables installed, you should be able to start it by running:
# /etc/init.d/iptables start

Assuming that your disribution has installed the correct iptables as modules, then these will be loaded. Most distros do have iptables in the kernel by default. If not, you will have to recompile the kernel.

Assuming that you do get iptables started, then you should download this code, and paste it into a file called firewall-script.sh

Copy the above to an editor and save it in /etc/init.d as rc.firewall. To make it executable cd to /etc/init.d and do as root in a console chmod +x rc.firewall. Now you need to get it to start automatically at boot time so do the following;
ln -s rc.firewall /etc/rc2.d/S89firewall
ln -s rc.firewall /etc/rc3.d/S89firewall
ln -s rc.firewall /etc/rc4.d/S89firewall
ln -s rc.firewall /etc/rc5.d/S89firewall

A tip here to make this quicker than typing the whole thing each time; when you have done the first one, up-arrow and the line will appear again so just use the left arrow to go back to rc2.d and change it to 3 then go to the end of the line and press return and so on.

I had the same pop up in Ubuntu 5.04 about could not grab mouse and eavesdropping. I did not see any problems. Nothing locked up. I was trying to open Synaptic. Synaptic still works. Untill recently I could not login anymore. I used Knoppix as a recovery disk to get all my impoortant files backed up and installed FreeBSD.

Get a cheap machine, like a Celeron 650 MHz. Put in two network cards. Make sure it has a CD drive. Go online and download the .iso for Smoothwall. Burn it to a CD. Hook up a monitor and keyboard to the Celeron. Boot from the Smoothwall CD you made. Install Smoothwall. After you get done, shut down Smoothwall. Hook up internet to the red interface, and your PC to the green interface. Then, boot Smoothwall. Boot your PC. Now you have a packet dropping firewall with a network address translator. This is not to be confused with a packet filtering firewall, which comes with most linux distros. A port scan can learn a lot about a machine with a packet filtering firewall. A packet dropping firewall looks like an unused IP to a port scanner. Unless someone knows your IP, and knows you have Smoothwall, it is impenetrable. it works flawlessly for years on end. I have never had it fail, or need rebooting. It makes you completely invisible. I tried the famous network security hacker, Saint, on it. I tried every test to hack that firewall. Everything timed out, with no result. Saint thought it was a dead connection. Saint is the most sophisticated network penetration tool available. It comes with SuSE linux. It is great for testing security. Don't use it for anything illegal. Saint is like jail bait. You can really, seriously get into trouble for scanning other people's systems. Scan your own, though.

Copy the above to an editor and save it in /etc/init.d as rc.firewall. To make it executable cd to /etc/init.d and do as root in a console chmod +x rc.firewall. Now you need to get it to start automatically at boot time so do the following;
ln -s rc.firewall /etc/rc2.d/S89firewall
ln -s rc.firewall /etc/rc3.d/S89firewall
ln -s rc.firewall /etc/rc4.d/S89firewall
ln -s rc.firewall /etc/rc5.d/S89firewall

A tip here to make this quicker than typing the whole thing each time; when you have done the first one, up-arrow and the line will appear again so just use the left arrow to go back to rc2.d and change it to 3 then go to the end of the line and press return and so on.

A better way to do that is to program a for loop, while loop, or do while loop.