Changes between Version 4 and Version 5 of WikiStart


Ignore:
Timestamp:
Nov 25, 2010, 10:04:05 PM (14 years ago)
Author:
huub
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • WikiStart

    v4 v5  
    2222Elke node heeft een lijstje met internetpoortjes en controleert welke beschikbaar zijn en kiest vervolgens de dichtstbijzijnde.
    2323
     24== Proxy packet filtering firewall ==
     25We gebruiken ipfw (aanzetten in /etc/rc.conf). Script ipfw.sh:
     26
     27{{{
     28#!/bin/sh -                                                 
     29# Based on /etc/rc.firewall                                 
     30
     31allowed2internet="80,443"
     32maxconnections="10"     
     33
     34# Suck in the configuration variables.
     35if [ -z "${source_rc_confs_defined}" ]; then
     36        if [ -r /etc/defaults/rc.conf ]; then
     37                . /etc/defaults/rc.conf     
     38                source_rc_confs             
     39        elif [ -r /etc/rc.conf ]; then       
     40                . /etc/rc.conf               
     41        fi                                   
     42fi                                           
     43
     44setup_loopback () {
     45        ############                                                                                             
     46        # Only in rare cases do you want to change these rules                                                   
     47        #                                                                                                         
     48        ${fwcmd} add 100 pass all from any to any via lo0                                                         
     49        ${fwcmd} add 200 deny all from any to 127.0.0.0/8                                                         
     50        ${fwcmd} add 300 deny ip from 127.0.0.0/8 to any                                                         
     51}                                                                                                                 
     52
     53############
     54# Set quiet mode if requested
     55#                           
     56case ${firewall_quiet} in   
     57[Yy][Ee][Ss])               
     58        fwcmd="/sbin/ipfw -q"
     59        ;;                   
     60*)                           
     61        fwcmd="/sbin/ipfw"   
     62        ;;                   
     63esac                         
     64
     65###########
     66# Set Internal/External Interface
     67#                               
     68driver=`echo ${internalif} | sed 's/[0-9]*//g'`
     69seq=`echo ${internalif} | sed 's/[a-zA-Z]*//g'`
     70
     71if [ ${seq} = 0 ]; then
     72  seq=`expr ${seq} \+ 1`
     73else                   
     74  seq=`expr ${seq} \- 1`
     75fi                     
     76
     77externalif="$driver$seq"
     78
     79# Get public ip
     80externalip=`ifconfig $externalif | awk '/inet/ { print $2 }'`
     81############                                                 
     82# Flush out the list before we begin.                       
     83#                                                           
     84${fwcmd} -f flush                                           
     85
     86setup_loopback
     87
     88
     89############
     90# Block the hosters network (and maybe others)
     91
     92for IP in ${firewall_block}
     93do                         
     94  ${fwcmd} add deny ip from any to ${IP} in via $internalif
     95done                                                       
     96
     97#############
     98# Outbound NAT setup
     99
     100${fwcmd} add nat 100 all from 172.16.0.0/12 to any out via $externalif
     101${fwcmd} add nat 100 all from any to $externalip in via $externalif
     102${fwcmd} nat 100 config if $externalif
     103
     104#############
     105# WL -> Internet
     106# Stateful firewalling
     107
     108${fwcmd} add 3000 check-state
     109# HTTP
     110${fwcmd} add 3001 allow tcp from 172.16.0.0/12 to any $allowed2internet in via $internalif setup limit src-addr $maxconnections
     111# HTTPS
     112
     113# Allow anything originating from me
     114${fwcmd} add 4001 allow ip from me to any keep-state
     115
     116# Allow on any interface
     117# Allow SSH
     118${fwcmd} add 5001 allow tcp from any to me 22 keep-state
     119
     120# Allow on internal interface
     121# DNS
     122${fwcmd} add 6001 allow ip from any to me 53 via $internalif keep-state
     123
     124# NTP
     125${fwcmd} add 6002 allow udp from any to me 123 via $internalif keep-state
     126
     127# HTTP-PROXY
     128${fwcmd} add 6003 allow tcp from any to me 3128 via $internalif keep-state
     129
     130# lvrouted
     131${fwcmd} add 6004 allow udp from 172.16.0.0/12 to me 12345 via $internalif keep-state
     132
     133# SNMP
     134${fwcmd} add 6005 allow udp from any to me 161 via $internalif keep-state
     135
     136# Block anything else
     137${fwcmd} add 65000 deny ip from any to any
     138}}}
     139
     140== lvrouted ==
     141Ook op de proxy wordt lvrouted gedraaid.
     142
     143Voor de nodes is aan lvrouted de -z optie toegevoegd: de default gateway (naar internet). In tegenstelling tot de configuratie met pen en proxies (waarbij de snelste internetverbinding werd gekozen) wordt nu gekozen voor de dichtstbijzijnde gateway (kleinste aantal hops) die beschikbaar is.
     144
     145
     146
    24147----
    25148
    26149= Welcome to Trac 0.11.6 =
    27 
    28 Trac is a '''minimalistic''' approach to '''web-based''' management of
    29 '''software projects'''. Its goal is to simplify effective tracking and handling of software issues, enhancements and overall progress.
    30 
    31 All aspects of Trac have been designed with the single goal to
    32 '''help developers write great software''' while '''staying out of the way'''
    33 and imposing as little as possible on a team's established process and
    34 culture.
    35150
    36151As all Wiki pages, this page is editable, this means that you can
     
    39154of the page. WikiFormatting will give you a detailed description of
    40155available Wiki formatting commands.
    41 
    42 "[wiki:TracAdmin trac-admin] ''yourenvdir'' initenv" created
    43 a new Trac environment, containing a default set of wiki pages and some sample
    44 data. This newly created environment also contains
    45 [wiki:TracGuide documentation] to help you get started with your project.
    46 
    47 You can use [wiki:TracAdmin trac-admin] to configure
    48 [http://trac.edgewall.org/ Trac] to better fit your project, especially in
    49 regard to ''components'', ''versions'' and ''milestones''.
    50 
    51 
    52 TracGuide is a good place to start.
    53 
    54 Enjoy! [[BR]]
    55 ''The Trac Team''
    56156
    57157== Starting Points ==