OSDN Git Service

Ver1.5.28 Changed to deny duplicated open, added udp send and ohters.
authorwatanaby <>
Fri, 1 Mar 2013 03:44:05 +0000 (03:44 +0000)
committerwatanaby <>
Fri, 1 Mar 2013 03:44:05 +0000 (03:44 +0000)
opengate/conf/opengatesrv.conf.sample
opengate/doc/Changes.html
opengate/opengatesrv/Makefile
opengate/opengatesrv/comm-cgi.c
opengate/opengatesrv/comm-ip6fw.c
opengate/opengatesrv/comm-ipfw.c
opengate/opengatesrv/ctrl-firewall.c
opengate/opengatesrv/main.c
opengate/opengatesrv/opengatesrv.h
opengate/opengatesrv/utilities.c

index 87f3e32..e0da257 100644 (file)
        <!-- Separate char between userID and extraID [userID@extraID] -->
        <UserIdSeparator>@</UserIdSeparator>
 
+       <!-- Port of Opengatemd to which close signal is sent -->
+       <!-- the signal renews information about mac address in md cache --> 
+       <!-- If opengatemd is not used, remove this setting --> 
+       <OpengateMdPort>4989</OpengateMdPort>
 
        <!-- #### Config for exceptional users, See below document ####
        ## To use below sample, remove the XML comment mark ##  -->
        #### TYPE 6 (Shibboleth) ####
        <AuthServer>
                 <Protocol>shibboleth</Protocol>
-               <UidAttribute>-uid-env-var-</UidAttribute>
-               <OrgAttribute>-org-env-var-</OrgAttribute>
+               [<UidAttribute>-uid-env-var-</UidAttribute>]
+               [<OrgAttribute>-org-env-var-</OrgAttribute>]
+               [<EppnAttribute>-eppn-env-var-</EppnAttribute>]
         </AuthServer>
 
        #   'UidAttiribute' means the environment variable having UserId
+       #       in the organization.
        #     E.G., 
-       #     <UidAttribute>uid eppn persistent-id targeted-id</UidAttribute>
+       #     <UidAttribute>uid persistent-id targeted-id</UidAttribute>
        #       left item has priority, if not found, search next item
 
        #   'OrgAttiribute' means the environment variable having Organization
        #     <OrgAttribute>o affiliation Shib-Identity-Provider</OrgAttribute>
        #       left item has priority, if not found, search next item
 
+       #   'EppnAttiribute' means the environment variable having
+       #     ePPN(edu person pricipal name 'user@org') or other global id 
+       #     E.G., 
+       #     <EppnAttribute>eppn mail</EppnAttribute>
+       #       left item has priority, if not found, search next item
+       #     If Uid and Eppn are defined, Uid has priority.
+
        #   Set 'opengateauth.cgi & opengatesrv.cgi' as SHIB-AUTH in .htaccess
        #    <FILES opengateauth.cgi>
        #      AuthType shibboleth
 
        <AuthServer>
                 <Protocol>shibboleth</Protocol>
-               <UidAttribute>uid eppn persistent-id targeted-id</UidAttribute>
-               <OrgAttribute>o affiliation Shib-Identity-Provider</OrgAttribute>
+               <UidAttribute>uid</UidAttribute>
+               <OrgAttribute>o</OrgAttribute>
+               <EppnAttribute>eppn</EppnAttribute>
+               
         </AuthServer>
 -->
 
index a996756..a85b2f8 100644 (file)
@@ -737,12 +737,765 @@ Opengate History</H3>
        Ver.1.5.25 at 2012.12.14
        </DT><DD>
        Fixed small bugs in http header and parameter[contributed by M.Tagawa]. 
-       </DD><DT>
+       </DD>
+
        Ver.1.5.26 at 2012.12.19
        </DT><DD>
        Added sqlite3_busy_timeout to reduce db-lock error. Added
        error checks.
        </DD>
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
+<HTML>
+<HEAD>
+       <META HTTP-EQUIV="CONTENT-TYPE" CONTENT="text/html; charset=utf-8">
+       <TITLE></TITLE>
+</HEAD>
+<BODY LANG="en-US" BGCOLOR="#fafff0" DIR="LTR">
+
+<H3>
+Opengate History</H3>
+<DL>
+       <DT>Ver.0.10 at 1999.8.30 
+       </DT><DD>
+       Initial Version. In this version, the Java applet is sent first and
+       the applet accepts the password. 
+       </DD><DT>
+       Ver.0.11 at 1999.9.19 
+       </DT><DD>
+       Stable Version. Reformed program. 
+       </DD><DT>
+       Ver.0.12 at 1999.11.2 
+       </DT><DD>
+       Support firewalls IPF and IPFW. 
+       </DD><DT>
+       Ver.0.20 at 1999.9.16 
+       </DT><DD>
+       Abandoned version. 
+       </DD><DT>
+       Ver.0.30 at 1999.10.16 
+       </DT><DD>
+       Changed to accept password with CGI. IPF support is discarded. 
+       </DD><DT>
+       Ver.0.31 at 1999.10.26 
+       </DT><DD>
+       Reformed User Interface. Java applet shows own window. 
+       </DD><DT>
+       Ver.0.32 at 1999.11.1 
+       </DT><DD>
+       Support for IPF. 
+       </DD><DT>
+       Ver.0.33 at 2000.6.17 
+       </DT><DD>
+       Support for IP forwarding. Discarded IPF support. 
+       </DD><DT>
+       Ver.0.40 at 2000.6.19 
+       </DT><DD>
+       Support for multiple authentication servers. 
+       </DD><DT>
+       Ver.0.41 at 2000.6.23 
+       </DT><DD>
+       Added function to close firewall when no packets were passed for a
+       set timespan. 
+       </DD><DT>
+       Ver.0.42 at 2000.6.28 
+       </DT><DD>
+       Added function to close firewall on abnormal server termination. 
+       </DD><DT>
+       Ver.0.50 at 2000.12.11 
+       </DT><DD>
+       Added function to exchange hello message with terminal. Firewall is
+       closed, when the client does not reply. Java output is included in
+       html window. 
+       </DD><DT>
+       Ver.0.51 at 2000.12.22 
+       </DT><DD>
+       Support for POP3 authentication. 
+       </DD><DT>
+       Ver.0.52a at 2001.1.19 
+       </DT><DD>
+       Exclusive execution of ipfw command. Deny multiple authentication
+       requests from a terminal. Change the method to get Java connection
+       address. Modified string sizes in the program. Many small
+       modifications. 
+       </DD><DT>
+       Ver.0.52b at 2001.1.24 
+       </DT><DD>
+       Reformed UNP library. 
+       </DD><DT>
+       Ver.0.52c at 2001.1.26 
+       </DT><DD>
+       Added DEBUG flag. Modified Directory setting. 
+       </DD><DT>
+       Ver.0.52d at 2001.1.30 
+       </DT><DD>
+       Modified no packet time setting. 
+       </DD><DT>
+       Ver.0.52e at 2001.2.5 
+       </DT><DD>
+       Corrected wrong comment. 
+       </DD><DT>
+       Ver.0.53a at 2001.2.7 
+       </DT><DD>
+       Directory setting integrated in Makefile. Support for logging MAC
+       address. 
+       </DD><DT>
+       Ver.0.53b at 2001.2.8 
+       </DT><DD>
+       Added check for empty userID or password. 
+       </DD><DT>
+       Ver.0.53c at 2001.2.10 
+       </DT><DD>
+       Replaced one accept window to two overlapping windows. 
+       </DD><DT>
+       Ver.0.53d at 2001.2.13 
+       </DT><DD>
+       Small modification on MAC address acquisition. 
+       </DD><DT>
+       Ver.0.54a at 2001.2.15 
+       </DT><DD>
+       Serious error (Ports destroyed during long execution) found and
+       fixed. 
+       </DD><DT>
+       Ver.0.55a at 2001.3.19 
+       </DT><DD>
+       Show messages in JavaApplet field. 
+       </DD><DT>
+       Ver.0.56a at 2001.3.29 
+       </DT><DD>
+       Detached UNP library (Many modifications to source) 
+       </DD><DT>
+       Ver.0.56b at 2001.4.14 
+       </DT><DD>
+       Modified document. (No modification to source) 
+       </DD><DT>
+       Ver.0.56c at 2001.4.24 
+       </DT><DD>
+       Reformed HTML to improve authentication response time. (Modification
+       to accept.html) 
+       </DD><DT>
+       Ver.0.56d at 2001.4.29 
+       </DT><DD>
+       Declaration of GPL. Added English documentation. (No modification to
+       source) 
+       </DD><DT>
+       Ver.0.57a at 2001.5.10 
+       </DT><DD>
+       Removed loop in ipfw-delete. (Modification to comm-ipfw.c) 
+       </DD><DT>
+       Ver.0.57b at 2001.5.11 
+       </DT><DD>
+       Changed Lockout time for ipfw exec. (Modification to opengatesrv.h) 
+       </DD><DT>
+       Ver.0.57c at 2001.5.25 
+       </DT><DD>
+       Display message when Java/JavaScript is disabled. (Modification to
+       accept.html) 
+       </DD><DT>
+       Ver.0.57d at 2001.11.21 
+       </DT><DD>
+       Changed timeout values (Modification to opengatesrv.h) 
+       </DD><DT>
+       Ver.0.57e at 2002.2.13 
+       </DT><DD>
+       Fixed redirect error in IE (Modification to topindex.html) 
+       </DD><DT>
+       Ver.0.60a at 2002.6.17 
+       </DT><DD>
+       Added authentication protocols: RADIUS, PAM, POP3S (Modifications:
+       Makefile, comm-auth.c, utilities.c, opengatesrv.h, opengatesrv.conf.
+       Additions: auth-pam.c, auth-pop3s.c, auth-rad.c) 
+       </DD><DT>
+       Ver.0.60b at 2002.6.18 
+       </DT><DD>
+       Added comments. 
+       </DD><DT>
+       Ver.0.70a at 2002.6.19 
+       </DT><DD>
+       Modified to control multi-language environment (Modifications:
+       Makefile, comm-cgi.c *.html Opengate.java) 
+       </DD><DT>
+       Ver.0.71a at 2002.6.24 
+       </DT><DD>
+       Refined installation procedure (Modifications: Makefile, comm-cgi.c
+       *.html) 
+       </DD><DT>
+       Ver.0.72a at 2002.7.1 
+       </DT><DD>
+       Messages are terminated with CR and LF (Modifications: comm-cgi.c
+       Opengate.java) 
+       </DD><DT>
+       Ver.0.73a at 2002.7.4 
+       </DT><DD>
+       Added jar (java archive) file, modified some documents
+       (Modifications: comm-cgi.c Makefile Add: Opengate.jar) 
+       </DD><DT>
+       Ver.0.73b at 2002.7.10 
+       </DT><DD>
+       Recovery of error messages added in Ver.0.57c but forgotten in
+       Ver.0.70a (Modifications: accept.html) 
+       </DD><DT>
+       Ver.0.73c at 2002.7.12 
+       </DT><DD>
+       Changed some documents 
+       </DD><DT>
+       Ver.0.73d at 2002.7.15 
+       </DT><DD>
+       More careful detaching from web server. (Modifications: main.c
+       comm-cgi.c) 
+       </DD><DT>
+       Ver.0.73e at 2002.8.7 
+       </DT><DD>
+       Fixed a serious bug in java applet introduced in Ver.0.70a. The
+       applet did not return hello to hello request in English message
+       mode.(Modifications: Opengate.java) Save index.html created during
+       web server installation. (Modifications: Makefile) 
+       </DD><DT>
+       Ver.0.80a at 2002.8.19 
+       </DT><DD>
+       Added Perl script for more flexible firewall control (Modifications:
+       main.c comm-ipfw.c opengatesrv.h Makefile, Additions:
+       conf/opengatefw.pl) Fixed a small mistake in debug mode
+       (Modifications: auth-pam.c) Modified installation procedure.
+       Opengate directory can be set in Makefile (Modifications: Makefile,
+       *.html). Added document to describe the system flow (Additions:
+       doc/progflow.html). 
+       </DD><DT>
+       Ver.0.80b at 2002.8.26 
+       </DT><DD>
+       Fixed a bug for checking overlapping requests (Modifications:
+       comm-ipfw.c) 
+       </DD><DT>
+       Ver.0.81a at 2002.8.26 
+       </DT><DD>
+       Added link to close network in No-java mode (Modifications:
+       accept.html, Makefile, comm-cgi.c, comm-java.c, main.c
+       ,opengatesrv.h) 
+       </DD><DT>
+       Ver.0.81b at 2002.8.27 
+       </DT><DD>
+       Removed userid from terminate link string (Modifications:
+       comm-cgi.c, comm-java.c), Modified accept page design
+       (Modifications: accept.html) 
+       </DD><DT>
+       Ver.0.81c at 2002.9.5 
+       </DT><DD>
+       Faulted Version. Removed. 
+       </DD><DT>
+       Ver.0.81d at 2002.9.9 
+       </DT><DD>
+       Fixed a mistake in URL string in HTML file. (Modifications:
+       ja/accept.html) Removed reference HTML document from archive. Added
+       description for maxuser=0 in installation document. 
+       </DD><DT>
+       Ver.0.81e at 2002.9.10 
+       </DT><DD>
+       Added checking for execl failure (Modifications: comm-ipfw.c,
+       comm-arp.c, main.c) 
+       </DD><DT>
+       Ver.0.82a at 2002.9.25 
+       </DT><DD>
+       Added skeleton routine to get user properties (Modifications:
+       opengatesrv.h, Makefile, main.c, comm-ipfw.c, opengatefw.pl,
+       Additions: comm-userdb.c) 
+       </DD><DT>
+       Ver.0.83a at 2002.10.7 
+       </DT><DD>
+       Do not permit reply to hello more than once (Modifications:
+       comm-java.c, opengatesrv.h) 
+       </DD><DT>
+       Ver.0.83b at 2003.1.6 
+       </DT><DD>
+       Add documentation about maximum number of TCP connections
+       (Modifications: install.html, install-e.html) 
+       </DD><DT>
+       Ver.0.90a at 2003.5.6 
+       </DT><DD>
+       Added duration input field in auth page, allowing prolonged usage
+       without java. To cope with hijacking and notting, mac-address and
+       packet-count are checked periodically. (Modifications: index.html,
+       index-ssl.html, accept.html, comm-cgi.c comm-java.c, comm-arp.c,
+       main.c, opengatesrv.h) 
+       </DD><DT>
+       Ver.0.90b at 2003.5.7 
+       </DT><DD>
+       Reset the DEBUG option. It was left out in the previous
+       version.(Modification: opengatesrv.h) 
+       </DD><DT>
+       Ver.0.90c at 2003.5.15 
+       </DT><DD>
+       Simplified the logic. (Modification: comm-java.c) 
+       </DD><DT>
+       Ver.0.90d at 2003.8.27 
+       </DT><DD>
+       Changed message in auth page. (Modification: index.html,
+       index-ssl.html) 
+       </DD><DT>
+       Ver.0.90e at 2003.9.24 
+       </DT><DD>
+       Display (firewall-rule-Number,userID,IPaddress) in process
+       title.(Modification: main.c) 
+       </DD><DT>
+       Ver.0.90f at 2003.9.25 
+       </DT><DD>
+       Added documentation (Modification: errcheck.html,errcheck-e.html) 
+       </DD><DT>
+       Ver.0.90g at 2003.11.28 
+       </DT><DD>
+       Fixed PAM-include error occurred on FreeBSD 5 (Modification:
+       auth-pam.c) 
+       </DD><DT>
+       Ver.0.90h at 2003.12.8 
+       </DT><DD>
+       Fixed Applet-NoReply error occurring in some browsers when removing
+       applet page. Modified install document (Modification: Opengate.java
+       and the compiled files, install.html,install-e.html) 
+       </DD><DT>
+       Ver.0.90i at 2003.12.16 
+       </DT><DD>
+       Modified parameters and documentation (Modification: opengatesrv.h,
+       makefile, index.html, index-ssl.html, accept.html, accept2.html,
+       install.html, install-e.html, qa.html, qa-e.html, errcheck.html,
+       errcheck-e.html) 
+       </DD><DT>
+       Ver.0.90j at 2004.9.21 
+       </DT><DD>
+       Fixed communication error occurring on some pop3/pop3s servers
+       (Modification: comm-auth.c, auth-pop3s.c) 
+       </DD><DT>
+       Ver.0.90k at 2005.2.3 
+       </DT><DD>
+       Added links to accept.html to cope with pop-up-blocked and
+       java-optional browser (Modification: accept.html) 
+       </DD><DT>
+       Ver.0.90l at 2005.2.4 
+       </DT><DD>
+       Fixed communication error with ftpserver sending back multi-line
+       greeting. Added error reporting code for fork/exec
+       (Modification:comm-auth.c, comm-ipfw.c) 
+       </DD><DT>
+       Ver.0.90m at 2005.2.7 
+       </DT><DD>
+       Added error check code for ipfw response (Modification:comm-ipfw.c) 
+       </DD><DT>
+       Ver.0.90n at 2005.3.21 
+       </DT><DD>
+       Added no-cache option to authentication pages
+       (Modification:index.html, index-ssl.html) 
+       </DD><DT>
+       Ver.1.0.0 at 2005.5.21 
+       </DT><DD>
+       Stable version is released (Modification: README) 
+       </DD><DT>
+       Ver.1.1.0 at 2005.5.27 
+       </DT><DD>
+       Added many parameters in conf file. Added test-programs. (Addition:
+       get-param.c,test-get-param.c,test-comm-auth.c,test-comm-ipfw.c,test-comm-java.c,test-console.sh
+       Modification:
+       README,main.c,comm-auth.c,comm-ipwf.c,comm-java.c,Makefile) 
+       </DD><DT>
+       Ver.1.1.1 and 1.0.1 at 2005.5.30 
+       </DT><DD>
+       Recompiled Java Applet with option '-target 1.1' to be compatible
+       with MicrosoftVM (Modification: Opengate.class,
+       OpengateClient.class, Opengate.jar) 
+       </DD><DT>
+       Ver.1.1.2 at 2005.7.13 
+       </DT><DD>
+       Commented out server parameter setting in config file
+       (modification:opengatesrv.conf) 
+       </DD><DT>
+       Ver.1.1.3 at 2005.12.1 
+       </DT><DD>
+       Fixed error when executing the child process. Thanks to K.Eguchi and
+       S.Uematsu (modification:comm-java.c, opengatefw.pl) 
+       </DD><DT>
+       Ver.1.2.0 at 2005.12.2 
+       </DT><DD>
+       Added IPv6 support [contributed by K.Eguchi] 
+       </DD><DT>
+       Ver.1.2.1 at 2005.12.15 
+       </DT><DD>
+       Changed NDP command option to be recognized by new NDP [contributed
+       by K.Eguchi] 
+       </DD><DT>
+       Ver.1.2.2 at 2006.1.6 
+       </DT><DD>
+       Fixed error occurring when a cgi has no argument. Added MRTG
+       function [contributed by K.Eguchi] 
+       </DD><DT>
+       Ver.1.1.4 and Ver.1.2.3 at 2006.2.2 
+       </DT><DD>
+       Added FTPS authentication. 
+       </DD><DT>
+       Ver.1.2.4 at 2006.3.14 
+       </DT><DD>
+       Modified documentation and comments. 
+       </DD><DT>
+       Ver.1.3.0 at 2006.3.22 
+       </DT><DD>
+       Changed address acquisition method for IPv4/IPv6 dual stack and
+       others. 
+       </DD><DT>
+       Ver.1.3.1 at 2006.3.27 
+       </DT><DD>
+       Simplified logic. Modified rulechk script. 
+       </DD><DT>
+       Ver.1.3.2 at 2006.4.3 
+       </DT><DD>
+       Changed Config file to XML form. Almost all parameters can now be
+       set in the file. 
+       </DD><DT>
+       Ver.1.3.3 at 2006.4.7 
+       </DT><DD>
+       Put back syslog setting to fixed value, and some bugs were fixed. 
+       </DD><DT>
+       Ver.1.3.4 at 2006.4.11 
+       </DT><DD>
+       Changed accept page description. 
+       </DD><DT>
+       Ver.1.3.5 at 2006.4.13 
+       </DT><DD>
+       Modified the errcheck and qa documentation. Added time information
+       in address encoding. Added retry information page. 
+       </DD><DT>
+       Ver.1.3.6 at 2006.4.14 
+       </DT><DD>
+       Changed syslog setting to config file, and some bugs were fixed. 
+       </DD><DT>
+       Ver.1.3.7 at 2006.4.20 
+       </DT><DD>
+       Added code and info to cope with abnormal actions, and some bugs
+       were fixed. 
+       </DD><DT>
+       Ver.1.3.8 at 2006.4.26 
+       </DT><DD>
+       Added code to remove overlapping rules and processes. 
+       </DD><DT>
+       Ver.1.3.9 at 2006.4.27 
+       </DT><DD>
+       Modified Java Applet to display long message. 
+       </DD><DT>
+       Ver.1.3.10 at 2006.5.1 
+       </DT><DD>
+       Added userID pattern-match function. Fixed bug when checking
+       parameters. 
+       </DD><DT>
+       Ver.1.3.11 at 2006.5.3 
+       </DT><DD>
+       Added code to match the duration max value in conf file with auth
+       page. 
+       </DD><DT>
+       Ver.1.3.12 at 2006.5.12 
+       </DT><DD>
+       Changed link in deny page from external site to auth page. 
+       </DD><DT>
+       Ver.1.3.13 at 2006.5.17 
+       </DT><DD>
+       Use FILE and LINE macro in error message. Fixed abnormal termination
+       bugs. 
+       </DD><DT>
+       Ver.1.3.14 at 2006.5.23 
+       </DT><DD>
+       Removed close-error message. Modified QA document. 
+       </DD><DT>
+       Ver.1.3.15 at 2006.10.14 
+       </DT><DD>
+       Fixed browser's long waiting after sending accept page and other
+       small bugs. 
+       </DD><DT>
+       Ver.1.4.0 at 2006.10.16 
+       </DT><DD>
+       Added client watch to http keep-alive, which is the alternative to
+       the watch with java applet. Use carefully, as this is a preliminary
+       release. 
+       </DD><DT>
+       Ver.1.4.1 at 2006.10.18 
+       </DT><DD>
+       Changed JavaScript to run on some systems. 
+       </DD><DT>
+       Ver.1.4.2 at 2006.10.19 
+       </DT><DD>
+       Ignore Http watch mode on HTTP/1.0 browser. 
+       </DD><DT>
+       Ver.1.4.3 at 2006.10.20 
+       </DT><DD>
+       Moved JavaScript from html-file to external js-file. Modified some
+       messages. 
+       </DD><DT>
+       Ver.1.4.4 at 2006.10.25 
+       </DT><DD>
+       Added automatic start of java applet on failing http keep-alive.
+       Modified http-get format. Added session-id. Fixed read bug. 
+       </DD><DT>
+       Ver.1.4.5 at 2006.10.28 
+       </DT><DD>
+       Added function to indicate disable clients for http/java watch. 
+       </DD><DT>
+       Ver.1.4.6 at 2006.11.11 
+       </DT><DD>
+       Changed dir mode to install properly. Added mac check. Fixed small
+       bugs. 
+       </DD><DT>
+       Ver.1.4.7 at 2006.11.18 
+       </DT><DD>
+       Fixed small bugs and modified pages. Added processing time
+       measurement for research. 
+       </DD><DT>
+       Ver.1.4.8 at 2006.11.19 
+       </DT><DD>
+       Fixed small bugs and modified pages and measurement items. 
+       </DD><DT>
+       Ver.1.4.9 at 2006.12.20 
+       </DT><DD>
+       Changed hello timing control from client side to server side. 
+       </DD><DT>
+       Ver.1.4.10 at 2006.12.26 
+       </DT><DD>
+       Changed parameter's name and value in config file. 
+       </DD><DT>
+       Ver.1.4.11 at 2007.2.2 
+       </DT><DD>
+       Added ldap/ldaps authentication. Fixed malfunction in exceptional
+       terminals. 
+       </DD><DT>
+       Ver.1.4.12 at 2007.2.4 
+       </DT><DD>
+       Removed watch-mode selection in authentication page. 
+       </DD><DT>
+       Ver.1.4.13 at 2007.2.17 
+       </DT><DD>
+       Added change to select time watch mode when the duration value is
+       entered. 
+       </DD><DT>
+       Ver.1.4.14 at 2007.3.2 
+       </DT><DD>
+       Fixed bug when IPv6 disabled. Shortened the default duration for
+       time watch mode. 
+       </DD><DT>
+       Ver.1.4.15 at 2007.3.22 
+       </DT><DD>
+       Fixed bug when dumping micro-second time information. 
+       </DD><DT>
+       Ver.1.4.16 at 2007.4.16 
+       </DT><DD>
+       Fixed bug for delayed favicon.ico request, occurring on IE7. 
+       </DD><DT>
+       Ver.1.4.17 at 2007.4.18 
+       </DT><DD>
+       Refined the bug fix of favicon.ico error. 
+       </DD><DT>
+       Ver.1.4.18 at 2007.4.23 
+       </DT><DD>
+       Added favicon.ico installation. 
+       </DD><DT>
+       Ver.1.4.19 at 2007.5.24 
+       </DT><DD>
+       Modified control of favicon.ico. 
+       </DD><DT>
+       Ver.1.4.20 at 2007.6.1 
+       </DT><DD>
+       Modified web pages to guide the users in the right direction. 
+       </DD><DT>
+       Ver.1.4.21 at 2007.6.14 
+       </DT><DD>
+       Modified Makefile and install document. Abort when unloading the
+       httpkeep page. 
+       </DD><DT>
+       Ver.1.4.22 at 2007.6.26 
+       </DT><DD>
+       Removed ipfw pass rule for established packets. 
+       </DD><DT>
+       Ver.1.4.23 at 2007.7.2 
+       </DT><DD>
+       Added config setting for multiple auth servers and auth server
+       timeout. 
+       </DD><DT>
+       Ver.1.4.24 at 2007.11.28 
+       </DT><DD>
+       Added seteuid control. Show auto time setting in auth page. 
+       </DD><DT>
+       Ver.1.4.25 at 2007.12.21 
+       </DT><DD>
+       Fixed typo in Makefile (change from Lockfile to LockFile). 
+       </DD><DT>
+       Ver.1.4.26 at 2008.2.29 
+       </DT><DD>
+       Fixed error on 64 bit machine. 
+       </DD><DT>
+       Ver.1.4.27 at 2008.3.3 
+       </DT><DD>
+       Fixed error when setting the default pam service name. Fixed
+       previous fix. 
+       </DD><DT>
+       Ver.1.4.28 at 2008.3.8 
+       </DT><DD>
+       Fixed error in pam authentication. 
+       </DD><DT>
+       Ver.1.4.29 at 2008.3.17 
+       </DT><DD>
+       Added code to perl script to prevent multiple logins. 
+       </DD><DT>
+       Ver.1.4.30 at 2008.3.18 
+       </DT><DD>
+       Fixed error in tools/mrtg. 
+       </DD><DT>
+       Ver.1.4.31 at 2008.4.10 
+       </DT><DD>
+       Modified ReconnectTimeout value in conf to fix disconnection issue
+       in some browsers. 
+       </DD><DT>
+       Ver.1.4.32 at 2008.5.22 
+       </DT><DD>
+       Fixed segmentation-fault in opengatefwd. 
+       </DD><DT>
+       Ver.1.4.33 at 2008.5.29 
+       </DT><DD>
+       Fixed install documentation. 
+       </DD><DT>
+       Ver.1.4.34 at 2008.6.27 
+       </DT><DD>
+       Removed ip6fw from default. 
+       </DD><DT>
+       Ver.1.4.35 at 2008.7.9 
+       </DT><DD>
+       Fixed browser's hangup on closing. 
+       </DD><DT>
+       Ver.1.4.36 at 2008.7.17 
+       </DT><DD>
+       Changed value of ActiveCheckInterval. Modified install.html. 
+       </DD><DT>
+       Ver.1.4.37 at 2009.8.18 
+       </DT><DD>
+       Fixed Radius error. 
+       </DD><DT>
+       Ver.1.4.38 at 2009.8.28
+       </DT><DD>
+       Modified english document.(No modification to source) [Contiributed by M. Hawk] 
+       </DD><DT>
+       Ver.1.5.0 at 2009.9.11
+       </DT><DD>
+       Removed JavaApplet mode. Removed ip6fw command.  
+       Added firewall tag rule. Added Sqlite3 database.
+       Added cookie authentication. 
+       Added function to return to requested url.
+       Use carefully, as this is a preliminary release. 
+       </DD><DT>
+       Ver.1.5.1 at 2009.9.15
+       </DT><DD>
+        Modified english document. Removed disabled item in conf file.
+       </DD><DT>
+       Ver.1.5.2 at 2009.10.4
+       </DT><DD>
+        Fixed malfunctions caused by remaining cookie and null http_host.
+       </DD><DT>
+       Ver.1.5.3 at 2009.10.19
+       </DT><DD>
+        Fixed mutex error in sqlite3.
+       </DD><DT>
+       Ver.1.5.4 at 2009.10.20
+       </DT><DD>
+        Fixed error in perl script parameter.
+       </DD><DT>
+       Ver.1.5.5 at 2010.4.1
+       </DT><DD>
+        Fixed error in ldap on AMD machine [contributed by K.Iwao]. 
+       Modified install.html.
+       </DD><DT>
+       Ver.1.5.6 at 2011.4.1
+       </DT><DD>
+        Fixed error in pop3s and ftps. 
+       Changed Japanese char-code from jis to utf-8.
+       </DD><DT>
+       Ver.1.5.7 at 2011.4.20
+       </DT><DD>
+        Fixed error in tools/rulechk [contributed by S.Horikawa]. 
+       </DD><DT>
+       Ver.1.5.8 at 2011.5.9
+       </DT><DD>
+        Fixed error on arp entry expiring [contributed by S.Horikawa]. 
+       </DD><DT>
+       Ver.1.5.9 at 2011.5.13
+       </DT><DD>
+        Fixed errors at including many cookies and in retry.html [contributed by S.Horikawa]. 
+       </DD><DT>
+       Ver.1.5.10 at 2011.5.25
+       </DT><DD>
+        Fixed error on needless connections [contributed by S.Horikawa]. 
+       </DD><DT>
+       Ver.1.5.11 at 2011.5.27
+       </DT><DD>
+        Fixed error on requesting favicon [contributed by S.Horikawa]. 
+       </DD><DT>
+       Ver.1.5.12 at 2011.6.16
+       </DT><DD>
+        Fixed error on reconnecting [contributed by S.Horikawa]. 
+       </DD><DT>
+       Ver.1.5.13 at 2011.9.29
+       </DT><DD>
+        Added Shibboleth/HttpBasic authentication.
+       </DD><DT>
+       Ver.1.5.14 at 2011.10.4
+       </DT><DD>
+       Added detection of NAT/Router using opengatemd
+       </DD><DT>
+       Ver.1.5.15 at 2011.12.23
+       </DT><DD>
+       Modified Shibboleth authentication to get IdP info.
+       </DD><DT>
+       Ver.1.5.16 at 2012.1.18
+       </DT><DD>
+       Added retry on accidental disconnection. 
+       Added userid as comment on ipfw rule
+       </DD><DT>
+       Ver.1.5.17 at 2012.2.13
+       </DT><DD>
+       Removed 2 error messages.
+       </DD><DT>
+       Ver.1.5.18 at 2012.2.28
+       </DT><DD>
+       Modified treatment of overlapped sessions. Fixed bugs.
+       </DD><DT>
+       Ver.1.5.19 at 2012.3.19
+       </DT><DD>
+       Added version display (at execution with -v in shell). Added client
+       address in INFO log.
+       </DD><DT>
+       Ver.1.5.20 at 2012.4.6
+       </DT><DD>
+       Added replacing the parameter redirectedurl in some html files. 
+       </DD><DT>
+       Ver.1.5.21 at 2012.4.11
+       </DT><DD>
+       Added message to avoid popup blocking in httpkeep page. 
+       </DD><DT>
+       Ver.1.5.22 at 2012.7.17
+       </DT><DD>
+       Modified a variable name to avoid misunderstanding. 
+       </DD><DT>
+       Ver.1.5.23 at 2012.11.21
+       </DT><DD>
+       Fixed error at loading httpkeep page.
+       </DD><DT>
+       Ver.1.5.24 at 2012.11.29
+       </DT><DD>
+       Modified string at address conversion error in opengatefwd.
+       </DD><DT>
+       Ver.1.5.25 at 2012.12.14
+       </DT><DD>
+       Fixed small bugs in http header and parameter[contributed by M.Tagawa]. 
+       </DD><DT>
+       Ver.1.5.27 at 2013.2.27
+       </DT><DD>
+       Modified to deny plural ipfw rules for one  ip address. 
+       Added ipfw rule in syslog message. 
+       Added udp sending to opengatemd(need to set udp port in conf
+       file).
+       Added dummy html for network connectivity check of iOS.
+       </DD><DT>
+       Ver.1.5.28 at 2013.3.1
+       </DT><DD>
+       Modified shibboleth setting.
+       </DD>
        </DL>
 <P>
 <B>Please see CVS on SourceForge.net to check the differences between
index 0709563..48f3a2a 100644 (file)
@@ -27,7 +27,7 @@ LIBSQLITE = -lsqlite3 -lpthread
 LIBS = -lssl -lcrypto -lradius -lpam -lezxml ${LIBLDAP} ${LIBSQLITE} -L../ezxml -L/usr/local/lib
 
 
-OBJS = utilities.o comm-auth.o comm-cgi.o watch-client.o comm-ipfw.o comm-ip6fw.c comm-arp.o comm-ndp.o error.o tcp_connect.o sock_ntop_host.o wrapper.o signal.o auth-pam.o auth-rad.o auth-pop3s.o comm-userdb.o get-param.o auth-ftps.o auth-ldap.o htmltemplate.o addr-convert.o get-mac.o ctrl-firewall.o ctrl-alarms.o 
+OBJS = utilities.o comm-auth.o comm-cgi.o watch-client.o comm-ipfw.o comm-ip6fw.c comm-arp.o comm-ndp.o error.o tcp_connect.o sock_ntop_host.o wrapper.o signal.o auth-pam.o auth-rad.o auth-pop3s.o comm-userdb.o get-param.o auth-ftps.o auth-ldap.o htmltemplate.o addr-convert.o get-mac.o ctrl-firewall.o ctrl-alarms.o udp-client.o
 MAINPROGO = main.o
 HDRS = opengatesrv.h
 MAINPROG = opengatesrv
@@ -103,6 +103,10 @@ install-html:
                mkdir ${INSTALLDOCPATH}
 .endif
                cp -R ../javahtml/* ${INSTALLDOCPATH}
+               # Make dummy page for network connectivity check of iOS
+               mkdir -p ${DOCUMENTROOT}/library/test/
+               cp ../javahtml/success.html ${DOCUMENTROOT}/library/test/
+
                #
                # Replace index.html.var
 .if exists(${DOCUMENTROOT}/index.html.var) && !exists(${DOCUMENTROOT}/index.html.var.original)
@@ -188,6 +192,8 @@ htmltemplate.o:     ${HDRS}
 
 addr-convert.o:        ${HDRS}
 
+udp-client.o:  ${HDRS}
+
 test-get-param.o:      ${HDRS}
 
 test-comm-auth.o:      ${HDRS}
index 52f5546..2fc16bb 100644 (file)
@@ -201,20 +201,31 @@ int getUserIdFromEnv(char *userid){
   /* if shibboleth or httpbasic, get uid from environment var */
   /* shibboleth */
   if(strcmp(GetConfValue("AuthServer/Protocol"), "shibboleth")==0){
-    pEnv=getenvEx(GetConfValue("AuthServer/UidAttribute"));
+    pEnv=getenvEx(GetConfValue("AuthServer/UidAttribute"),TRUE,TRUE);
     if(!isNull(pEnv)){
       strncpy(userid, pEnv, USERMAXLN);
 
-      /* if idp string can be get from env variable, concatinate it as uid@idp */
-      pEnv=getenvEx(GetConfValue("AuthServer/OrgAttribute"));
+      /* if idp string can be get from env variable, concatinate it as uid@org */
+      pEnv=getenvEx(GetConfValue("AuthServer/OrgAttribute"),TRUE,TRUE);
       if(!isNull(pEnv)){
        strncat(userid, GetConfValue("UserIdSeparator"), USERMAXLN);
        strncat(userid, pEnv, USERMAXLN);
       } 
       ret=TRUE;
-    }else{
+    }
+
+    /* get from env-variable for EPPN(edu person principal name) attribute */
+    else{
+      pEnv=getenvEx(GetConfValue("AuthServer/EppnAttribute"),TRUE,FALSE);
+      if(!isNull(pEnv)){
+       strncat(userid, pEnv, USERMAXLN);
+       ret=TRUE;
+      }
+    }
+
+    /* no env-variable is found */
+    if(ret==FALSE){
       err_msg("ERR at %s#%d: Cannot get user info from shibboleth",__FILE__,__LINE__);
-      ret=FALSE;
       PutClientMsg("Cannot get user info from shibboleth<br>Check shibboleth setting in .htaccess and other");
       exit(0);
     }    
index 9147401..40ecdd8 100644 (file)
@@ -134,7 +134,10 @@ void closeClientGate6(struct clientAddr *pClientAddr, char *userid, char *macAdd
   sec=(time_l-hour*60*60-min*60);
   err_msg("CLOS: user %s from %s at %s ( %02d:%02d:%02d )",
          userid, pClientAddr->ipAddr, macAddr6, hour,min,sec);
-  
+
+  /* send message to opengatemd server to renew the info in md cache */
+  PutMacAddressToOpengateMd(macAddr6);
   return;
 }
 
index 4a1558f..0838fe4 100644 (file)
@@ -136,6 +136,9 @@ void closeClientGate4(struct clientAddr *pClientAddr, char *userid, char *macAdd
   err_msg("CLOS: user %s from %s at %s ( %02d:%02d:%02d )",
          userid, pClientAddr->ipAddr, macAddr4, hour,min,sec);
 
+  /* send message to opengatemd server to renew the info in md cache */
+  PutMacAddressToOpengateMd(macAddr4);
+
   return;
 }
 
index 976d3aa..d6baf10 100644 (file)
@@ -37,7 +37,6 @@ int openClientGate(char *clientAddr4, char *macAddr4, char *clientAddr6, char *m
 {
   int ret;
   struct clientAddr *pLastClientAddr=NULL;
-  int duplicateRule4=0, duplicateRule6=0;
 
   switch(ipStatus){
 
@@ -46,20 +45,22 @@ int openClientGate(char *clientAddr4, char *macAddr4, char *clientAddr6, char *m
     
     /*** at first, open IPv4 gate *****/
     ret=OpenClientGate4(clientAddr4, userid, macAddr4, userProperty);
-    if(ret==0 || ret<-2){ /* normally open or duplicated open */
+    if(ret==0){ /* normally open */
 
       /* open success */
       err_msg("OPEN: user %s from %s at %s", userid, clientAddr4, macAddr4);
 
       /* create new address list. head and tail pointer point the same item. */
       pLastClientAddr=pClientAddr=CreateAddrListItem(clientAddr4,ruleNumber4,IPV4);
+    }
 
-      /* save dupliacted rule */
-      if(ret<-2) duplicateRule4=-ret;
+    /* dupliacted rules */
+    else  if(ret<-2){
+      return FALSE;
     }
 
-    /* open fail */
-    else if(ret==-2 || ret==-1 || ret>0){
+    /* some failure */
+    else {
       PutClientMsg("Error: Please contact to the administrator");
       return FALSE;
     }
@@ -67,18 +68,21 @@ int openClientGate(char *clientAddr4, char *macAddr4, char *clientAddr6, char *m
 
     /*** next, open IPv6 gate *****/
     ret=OpenClientGate6(clientAddr6, userid, macAddr6, userProperty);
-    if(ret==0 || ret<-2){ /* normally open or duplicated open */
+    if(ret==0){ /* normally open */
 
       /* open success */
       err_msg("OPEN: user %s from %s at %s", userid, clientAddr6, macAddr6);
 
       /* add the address info to list */
       pLastClientAddr->next = CreateAddrListItem(clientAddr6,ruleNumber6,IPV6);
+    }
 
-      /* save dupliacted rule */
-      if(ret<-2) duplicateRule6=-ret;
+    /* save dupliacted rule */
+    else if(ret<-2){
+      return FALSE;
     }
-    /* open fail */
+
+    /* some failure */
     else{
       /* remove previously registered ipv4 rule from list */ 
       if(pClientAddr!=NULL && pClientAddr->ipType==IPV4){
@@ -86,13 +90,10 @@ int openClientGate(char *clientAddr4, char *macAddr4, char *clientAddr6, char *m
        free(pClientAddr);
        pClientAddr=NULL;
       }
-      /* some system error */
-      if(ret==-2 || ret==-1 || ret>0){
-       PutClientMsg("Error: Please contact to the administrator");
-       return FALSE;
-      }
+      PutClientMsg("Error: Please contact to the administrator");
+      return FALSE;
     }
-      break;  /* case IPV46DUAL end */
+    break;  /* case IPV46DUAL end */
 
 
     /***** if client have IPv4 only, do below *******/
@@ -100,7 +101,7 @@ int openClientGate(char *clientAddr4, char *macAddr4, char *clientAddr6, char *m
 
     /* open IPv4 gate */
     ret=OpenClientGate4(clientAddr4, userid, macAddr4, userProperty);
-    if(ret==0 || ret<-2){ /* normally open or duplicated open */
+    if(ret==0){ /* normally open */
 
       /* open success */
       err_msg("OPEN: user %s from %s at %s", userid, clientAddr4, macAddr4);
@@ -108,13 +109,15 @@ int openClientGate(char *clientAddr4, char *macAddr4, char *clientAddr6, char *m
       /* create new address list. head and tail pointer point the same item. */
       pLastClientAddr=pClientAddr
        =CreateAddrListItem(clientAddr4,ruleNumber4,IPV4);
+    }
 
-      /* save dupliacted rule */
-      if(ret<-2) duplicateRule4=-ret;
+    /* dupliacted rule */
+    else if(ret<-2){
+      return FALSE;
     }
 
-    /* open fail */
-    else if(ret==-2 || ret==-1 || ret>0){
+    /* some failure */
+    else{
       PutClientMsg("Error: Please contact to the administrator");
       return FALSE;
     }
@@ -125,7 +128,7 @@ int openClientGate(char *clientAddr4, char *macAddr4, char *clientAddr6, char *m
   case IPV6ONLY:
     /* open IPv6 gate */
     ret=OpenClientGate6(clientAddr6, userid, macAddr6, userProperty);
-    if(ret==0 || ret<-2){ /* normally open or duplicated open */
+    if(ret==0){ /* normally open */
 
       /* open success */
       err_msg("OPEN: user %s from %s at %s", userid, clientAddr6, macAddr6);
@@ -133,13 +136,15 @@ int openClientGate(char *clientAddr4, char *macAddr4, char *clientAddr6, char *m
       /* create new address list. head and tail pointer point the same item. */
        pLastClientAddr=pClientAddr
         =CreateAddrListItem(clientAddr6,ruleNumber6,IPV6);
+    }
 
-      /* save dupliacted rule */
-      if(ret<-2) duplicateRule6=-ret;
+    /* dupliacted rule */
+    else if(ret<-2){
+      return FALSE;
      }
 
     /* open fail */
-    else if(ret==-2 || ret==-1 || ret>0){
+    else{
       PutClientMsg("Error: Please contact to the administrator");
       return FALSE;
     }
@@ -147,25 +152,10 @@ int openClientGate(char *clientAddr4, char *macAddr4, char *clientAddr6, char *m
 
   default:
     err_msg("ERR at %s#%d: abnormal IP versions %d",__FILE__,__LINE__,ipStatus);
+    return FALSE;
 
   } /* switch end */
   
-
-  /* if duplicated rules exist, ignore */
-  if(duplicateRule4>0 || duplicateRule6>0){
-
-    /* to cope to modification of IPv4 addr in Dual stack(send as http param) */ 
-    if(ipStatus==IPV46DUAL && IsSameMacAddr(macAddr4, macAddr6)==FALSE){
-      err_msg("ERR at %s#%d: arp and ndp return different mac addr",
-             __FILE__,__LINE__);
-      PutClientMsg("Error. Please End Web and Retry. ");
-      return FALSE;
-
-    }else{
-       return TRUE;
-    }
-  }
-
   return TRUE;
 }
 
index a907d41..0fb41dc 100644 (file)
@@ -200,7 +200,10 @@ int  main(int argc, char **argv)
 
   /* open firewall for the client */
   if(OpenClientGate(clientAddr4,macAddr4,clientAddr6,macAddr6,
-                   userid,userProperty,ipStatus)==FALSE) return 0;
+                   userid,userProperty,ipStatus)==FALSE){
+    PutClientMsg("Error: Close this browser and retry");    
+    return 0;
+  }
   timeIn=time(NULL);
 
   /* set (ruleNumber,userid,clientAddr) in process title */
@@ -398,13 +401,14 @@ void logConnectMode()
     time3usec += 1000000; time3sec--;
   }
 
-  if(debug>0) err_msg("INFO: user=%s watchmode=%s procsec=%ld.%06ld,%ld.%06ld,%ld.%06ld ipversion=%d ipaddr=%s,%s macaddr=%s useragent=%s",
+  if(debug>0) err_msg("INFO: user=%s watchmode=%s procsec=%ld.%06ld,%ld.%06ld,%ld.%06ld ipversion=%d ipaddr=%s,%s macaddr=%s ipfwrule=%s,%s useragent=%s",
                      userid, mode[conMode], 
                      time1sec,time1usec,
                      time2sec,time2usec,
                      time3sec,time3usec,
                      ipStatus,
                      clientAddr4,clientAddr6,macAddr4,
+                     ruleNumber4, ruleNumber6,
                      getenv("HTTP_USER_AGENT"));
 }
 
index 109909e..7b73b1a 100644 (file)
@@ -219,7 +219,7 @@ int Listen(int fd, int backlog);
 Sigfunc * Signal(int signo, Sigfunc *func);
 void * Malloc(size_t size);
 
-char* getenvEx(char* env);
+char* getenvEx(char* env, int pre, int post);
 
 /* address encode and decode */
 int AddrEncode(char encodeAddr[], char dotSepAddr[]);
@@ -247,4 +247,6 @@ int EnableAlarm(void);
 int DisableAlarm(void);
 void listAlarm(void);
 
-
+/* udp-client.c */
+int PutMacAddressToOpengateMd(char* macAddress);
+int PutDataToUdpPort(char* udpServerAddr, char* udpServerPort, char* buff);
index bde2a77..81d8d11 100644 (file)
@@ -366,7 +366,6 @@ void createCookie(char *cookie)
   md5hex(cookie, SIDMAXLN, str);
 }
 
-
 /****************************************************/
 /* getenv for multiple variables                    */
 /*             after replacing '-' with '_'         */
@@ -374,22 +373,23 @@ void createCookie(char *cookie)
 /* if env = "ab cd-ef-gh ijk"                       */
 /*  repeat getenv until getting non-null value      */
 /*  getnev("ab"),getenv("cd_ef_gh"),getenv("ijk")   */
-/*                                                  */
-/* if the result value includes ' ' or '@'          */
-/*   convert these char to '_' to avoid side effect */ 
+/* if pre=TRUE convert '-' to '_' in env-var name   */
+/* if post=TRUE convert ' '|'@' to '_' in get-str   */
 /****************************************************/
-char* getenvEx(char* env){
+char* getenvEx(char* env, int pre, int post){
   char work[BUFFMAXLN];
   char* envValue="";
   char* p=NULL;
   char* thisVar=NULL;
   char* nextVar=NULL;
+  int found=FALSE;
 
   /* copy string not to destroy it */
   strncpy(work, env, BUFFMAXLN);
 
   /* repeat for variables */
   thisVar=nextVar=work;
+
   while(!isNull(thisVar)){
 
     /* skip preceeding space in string */
@@ -405,26 +405,36 @@ char* getenvEx(char* env){
       *p='\0';                /* set end of this variable */
       nextVar=p+1;            /* and start of next variable */
     }
+
     /* replace '-' in string with '_' */
-    for(p=thisVar; *p!='\0'; p++){
-      if(*p=='-') *p='_';
+    if(pre){
+      for(p=thisVar; *p!='\0'; p++){
+       if(*p=='-') *p='_';
+      }
     }
-    
+
     /* exeute getenv. if success, exit loop */
     envValue = getenv(thisVar);
-    if(!isNull(envValue)) break;
+    if(!isNull(envValue)){
+      found=TRUE;
+      break;
+    }
 
     /* try next variable */
     thisVar=nextVar;
   }
 
+  /* getting no data */
+  if(!found) return NULL;
+
   /* convert ' ' and '@' to '_' */
-  for(p=envValue; *p!='\0'; p++){
-    if(*p==' ') *p='_';
-    if(*p=='@') *p='_';
+  if(post){
+    for(p=envValue; *p!='\0'; p++){
+      if(*p==' ') *p='_';
+      if(*p=='@') *p='_';
+    }
   }
-  
+
   return envValue;
 }