Changeset 1104

Show
Ignore:
Timestamp:
05/31/08 18:21:29 (6 months ago)
Author:
mbr
Message:

- Bugfix to not open ports that are not specifically requested in an SPA
packet even if those ports are listed in the OPEN_PORTS variable in the
access.conf file.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • fwknop/trunk/CREDITS

    r1095 r1104  
    7979    - Helped with the testing process for fwknop-1.8.2 and OS X support. 
    8080    - Suggested the integration of SHA256 for replay attack detection. 
     81    - Suggested the OPEN_PORTS fix to not open ports that are not 
     82      specifically requested in an SPA packet. 
     83    - Noticed the bug where the "keep-state" option was not noticed when 
     84      checking for state tracking rules in ipfw policies. 
    8185 
    8286Mate Wierdl 
  • fwknop/trunk/ChangeLog

    r1099 r1104  
    6565      as possible within the boot sequence so that the system is ready to run 
    6666      fwknop. 
     67    - Bugfix to not open ports that are not specifically requested in an SPA 
     68      packet even if those ports are listed in the OPEN_PORTS variable in the 
     69      access.conf file. 
    6770    - Updated to version 5.47 of the Digest::SHA module. 
    6871    - Updated to version 0.7 of the IPTables::ChainMgr module (includes 
  • fwknop/trunk/TODO

    r1063 r1104  
    8484 
    8585 
    86  - Bugfix for opening all ports instead of just the requested ones. 
    8786 - Doc links in email messages linking back to help docs on cipherdyne.org 
    8887 - Integrate with clients programs besides SSH. 
     
    123122 - Firefox SPA extension. 
    124123 - Finish fwknop tutorial. 
    125  - Bugfix for installing Digest::SHA via the RPM. 
  • fwknop/trunk/fwknopd

    r1100 r1104  
    776776        $digest, $access_hr) = @_; 
    777777 
    778     my $allow_src  = ''; 
    779     my %open_ports = (); 
    780     my %nat_info   = (); 
     778    my $allow_src   = ''; 
     779    my %open_ports  = (); 
     780    my %grant_ports = (); 
     781    my %nat_info    = (); 
    781782 
    782783    if ($access_hr->{'DISABLE_FW_ACCESS'}) { 
     
    838839 
    839840        if ($access_hr->{'PERMIT_CLIENT_PORTS'}) { 
    840             $open_ports{$allow_proto}{$allow_port} = ''; 
     841            $grant_ports{$allow_proto}{$allow_port} = ''; 
    841842        } else { 
    842             unless (defined $open_ports{$allow_proto} and 
     843            if (defined $open_ports{$allow_proto} and 
    843844                    defined $open_ports{$allow_proto}{$allow_port}) { 
     845                $grant_ports{$allow_proto}{$allow_port} = ''; 
     846            } else { 
    844847                &logr('[-]', "IP $allow_src not permitted to open " . 
    845848                    "$allow_proto/$allow_port (SOURCE line num: " . 
     
    868871 
    869872                if ($access_hr->{'PERMIT_CLIENT_PORTS'}) { 
    870                     $open_ports{$proto}{$port} = ''; 
     873                    $grant_ports{$proto}{$port} = ''; 
    871874                } else { 
    872                     unless (defined $open_ports{$proto} and 
     875                    if (defined $open_ports{$proto} and 
    873876                            defined $open_ports{$proto}{$port}) { 
     877                        $grant_ports{$proto}{$port} = ''; 
     878                    } else { 
    874879                        &logr('[-]', "IP $allow_src not permitted to open " . 
    875880                            "$proto/$port (SOURCE line num: " . 
     
    932937        } 
    933938        my $port_ctr = 0; 
    934         for my $proto (keys %open_ports) { 
    935             for my $port (keys %{$open_ports{$proto}}) { 
     939        for my $proto (keys %grant_ports) { 
     940            for my $port (keys %{$grant_ports{$proto}}) { 
    936941                $port_ctr++; 
    937942            } 
     
    984989    ### grant access through the firewall 
    985990    &grant_access($allow_src, $msg_hr, \%nat_info, 
    986         {}, \%open_ports, $access_hr); 
     991        {}, \%grant_ports, $access_hr); 
    987992 
    988993    return 1;