Changeset 128


Ignore:
Timestamp:
Oct 5, 2007, 8:33:24 PM (12 years ago)
Author:
rainer
Message:

New option for portcheck to ignore selected ports. Released as 2.3.8.

Location:
trunk
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/docs/Changelog

    r127 r128  
    22        * new option PortCheckIgnore = interface:portlist
    33
    4 2.3.7:
     42.3.7 (13-09-2007):
    55        * Makefile.in: fix 'make deb' target, wrong name of config file
    66          written to debian/conffiles (reported by marc)
  • trunk/src/sh_portcheck.c

    r127 r128  
    356356          ptr->status = SH_PORT_MISS;
    357357
    358           if ((ptr->flag != SH_PORT_REQ) && (ptr->flag != SH_PORT_OPT))
     358          if ((ptr->flag != SH_PORT_REQ) && (ptr->flag != SH_PORT_OPT) && (ptr->flag != SH_PORT_IGN))
    359359            {
    360360              if (portchk_debug && report)
  • trunk/test/test.sh

    r68 r128  
    164164    echo "  (1) testcompile.sh (2) testhash.sh     (3) testrun_1.sh   (4) testrun_1a.sh"
    165165    echo "  (5) testext.sh     (6) testtimesrv.sh  (7) testrun_1b.sh  (8) testrun_1c.sh"
    166     echo "  (9) testrun_1d.sh"
     166    echo "  (9) testrun_1d.sh (10) testrun_1e.sh"
    167167    echo " (20) testrun_2.sh  (21) testrun_2a.sh  (22) testrun_2b.sh (23) testrun_2c.sh"
    168168    echo " (24) testrun_2d.sh"
     
    285285#
    286286#
    287 if test x$UID != x; then
     287if test x$UID != x -a x$UID != x0; then
    288288  TRUST="--with-trusted=0,2,$UID"
    289289else
    290   TRUST="--with-trusted=0,2,500"
     290  TRUST="--with-trusted=0,2,1000"
    291291fi
    292292export TRUST
  • trunk/test/testrun_1e.sh

    r67 r128  
    2323export BUILDOPTS
    2424
    25 MAXTEST=2; export MAXTEST
     25MAXTEST=3; export MAXTEST
     26
     27PORTPOLICY_3="
     28[ReadOnly]
     29file=${BASE}
     30[PortCheck]
     31PortCheckActive = yes
     32PortCheckUDP = no
     33"
     34
     35chk_portdata_3 () {
     36    one_sec_sleep
     37
     38    egrep 'CRIT.*POLICY \[ServiceNew\]' $LOGFILE >/dev/null 2>&1
     39    if [ $? -eq 0 ]; then
     40       
     41        [ -z "$verbose" ] || log_msg_fail "Open ports";
     42        return 1
     43    fi
     44}
     45
     46refine_portpolicy_3 ()
     47{
     48    cat "$LOGFILE" | grep ServiceNew | sed 's/.*port //' | awk '{ print $1 }' | \
     49    while read line; do
     50        echo "PortCheckIgnore=$line" >>"${RCFILE}"
     51    done
     52    echo "PortCheckIgnore=2026" >>"${RCFILE}"
     53    echo "PortCheckIgnore=2027" >>"${RCFILE}"
     54    echo "PortCheckIgnore=2028" >>"${RCFILE}"
     55    echo "PortCheckIgnore=2029" >>"${RCFILE}"
     56}
     57
    2658
    2759PORTPOLICY_2="
Note: See TracChangeset for help on using the changeset viewer.