Clarkconnect

Yum Priorities - Clarkconnect 5.0 / Centos

HOWTO - Add yum priorities plugin to ClearOS5.1 / ClarkConnect 5.0 so that additional repositories and additional packages can be added without fear of breaking your existing install
INSTALL

Cribbed from this page
http://wiki.centos.org/AdditionalResources/Repositories?action=show&redi...

Grab the yum-priorities package from
http://mirror.centos.org/centos-5/5.5/extras/i386/RPMS/yum-priorities-1....

Realtek Drivers - Compiled for CC5.0, Kernel 2.6.18-128.2.16v5-i686

UPDATE!: You can now get hold of these drivers via RPM if you wish, they are recompiled from the elrepo sources.
ftp://starlane.gotdns.org/elrepo-kmod/

Below are the latest Realtek drivers compiled for ClarkConnect5.0 - and all the chipsets outlined for each driver. See README files for instruction on installation

Getting the most out of Grub

The grub bootloader is particularly useful, especially when upgrading and testing new kernels. I recently found a way to modifiy the default boot config to make it useful when you wish to remotely upgrade a kernel and boot into it once only without being at the console to change the default back.

My current grub config:-

AMD K6 processors and RHEL / CentOS kernels above 2.6.9-67

Newer RHEL4 and CentOS kernels above 2.6.9-67 appear to have a bug which means that they will not boot with old AMD K6 processors, This also applies to Clarkconnect which is based on the above (I found from release 4.2 onwards).  it is to do with CPU checks carried out that the K6 processors don't actually support causing a kernel panic. This is very frustrating if you are trying to upgrade a kernel remotely ;-)

RT61 Wireless setup in managed mode on Clarkconnect (for WPA2)

Here is my guide on how to configure and setup my Belkin 802.11b/g PCI card (based on the Ralink RT61 chipset) on Clarkconnect 4.3 CE

Block a high bandwidth host from snort using BPF rule

Sometimes, there comes a time when a high bandwidth host is taking up valuable precious resources on your server, and snort is struggling to keep up with the demand. This is a simple way to block snort from seeing / processing that traffic and save the resources for catching bad traffic from other hosts.

This also helps if you happen to have your IDS behind a firewall and your LAN traffic passes through that same interface

To do this simply create a file, named whatever you like (mine is /etc/snort/bpf.conf)

add: (changin the IP for the host you wish to ignore)

Iptables fun! Firewall rule examples

Some examples of the power of iptables..the ip is defined as 123.123.123.123, substitute with your own. You can find out more by looking at the iptables manpage. Depending on your firewall configuration, not all setups have an explicit 'drop' at the end of the chain, therefore you maybe able to append the rules rather than insert using -A

Block single external host (change ethX for your WAN interface)

iptables -I INPUT -s 123.123.123.123 -i ethX -j DROP

Automatically add snortsam text to new snort rules

So we have oinkmaster - a script that will update all your snort rules for you very conveniently. We also have snortsam blocking IP's on custom rules which have fwsam:src 1day;) added to the end...the thing is the new rules don't so how do we update the new rules with the following text so that all our intrusion protection system stays up to date?

Script setup - getting the basics in place

Ok well, in my (many) google searches for bash scripting I stumbled across a site over here, that hosts several samples of text manipulation scripts amongst others. The reason for posting this up is the excellent templates the author uses for setting up a script, which includes simple help description, author, and usage information.

I've pasted a sample below for info: Credit of which is due to Dawid Michalczyk

Snort Performance Statistics

NOTE: This was written for use on the Smoothwall firewall, however it will work well on any other distro - just ignore the sections about amendements to the webconfig interface. (Step H)

Block whole country IP's from your firewall - Iptables / Linux

This following small script will automatically read the lines in Country IP range files from http://www.ipdeny.com and add them to your firewall

Create a file called zoneblock using the following text, then 'chmod +x zoneblock' to make it executable

Just download the zone file you want for the country you want (you can do this using wget), then run Code:


System Information Script - Linux

I've had a bit of time on my hands recently, so I've put together a little script which compiles all the Clarkconnect system setup information, and then creates an html output file which can then be copied / pasted into the forum or for your own information. Saves having to remember all those funny commands to generate the output! It also parses the config files to remove commented lines and spaces giving you the real config parameters.

I would be pleased to know of any feedback / comments etc.

It summarises the following info:

Installing a wireless USB dongle in linux (Zydas zd1211)

How to install a Zydas USB 802.11b/g Dongle on ClarkConnect (Home 3.2) and act as an Access Point. The following is how I managed to install wireless drivers in linux, most of the principles will apply to other distros. (but specifically Clarkconnect which is based on Redhat / Centos)

Install the devel and wireless packages required to build the module
Code:

User login

Navigation

Poll

What wireless chipset do you use in Linux?: