Ignore:
Timestamp:
20/05/08 17:11:20 (12 years ago)
Author:
pjkersha
Message:
  • New ndg.security.common.zsi_util.httpproxy.ProxyHTTPConnection class replaces urllib2client - easier to fit into existing ZSI client framework.
  • Further OpenID integration into Single Sign On Service. User now authenticates OK but patches needed to AuthKit? + need to handle return_to URL dynamically according to page visited before WAYF call.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • TI12-security/trunk/python/ndg.security.server/ndg/security/server/sso/sso/config/ssoServiceMiddleware.py

    r3896 r3914  
    3939             
    4040        appGlobals.ndg = ndg 
    41            
     41        self.globals = appGlobals 
     42         
    4243    def __call__(self, environ, start_response): 
    4344         
     
    8586              defSection='DEFAULT',  
    8687              layoutSection='layout', 
    87               wssSection='NDG_SECURITY.wssecurity'): 
     88              wssSection='WSSecurity'): 
    8889        '''Extract content of config file object into self''' 
    8990               
     
    105106                        'No "sslCACertFilePathList" security setting' 
    106107 
     108 
     109        # HTTP Proxy setting for web service connections... 
     110         
     111        # Override an http_proxy env setting   
     112        if self.cfg.has_option(defSection, 'httpProxyHost'): 
     113            self.httpProxyHost = self.cfg.get(defSection, 'httpProxyHost') 
     114        else: 
     115            self.httpProxyHost = None 
     116         
     117        # Set this to True if the http_proxy environment variable should be 
     118        # ignored in this case 
     119        if self.cfg.has_option(defSection, 'ignoreHttpProxyEnv'): 
     120            self.ignoreHttpProxyEnv = self.cfg.getboolean(defSection,  
     121                                                          'ignoreHttpProxyEnv') 
     122        else: 
     123            self.ignoreHttpProxyEnv = False 
     124             
     125             
    107126        # If no separate WS-Security config file is set then read these params 
    108127        # from the current config file 
     
    136155        self.wayfuri='%s/wayf' % self.server 
    137156 
     157        # Flag to enable OpenID interface 
     158        try: 
     159            self.enableOpenID = self.cfg.getboolean(defSection, 'enableOpenID') 
     160        except ConfigParser.NoOptionError: 
     161            self.enableOpenID = False 
     162             
    138163        self.localLink=self.cfg.get(layoutSection, 'localLink', None) 
    139164        self.localImage=self.cfg.get(layoutSection, 'localImage', None) 
    140         self.localAlt=self.cfg.get(layoutSection, 'localAlt', 'Visit Local Site') 
    141         self.ndgLink=self.cfg.get(layoutSection, 'ndgLink', 'http://ndg.nerc.ac.uk') 
     165        self.localAlt=self.cfg.get(layoutSection, 'localAlt',  
     166                                   'Visit Local Site') 
     167        self.ndgLink=self.cfg.get(layoutSection, 'ndgLink',  
     168                                  'http://ndg.nerc.ac.uk') 
    142169        self.ndgImage=self.cfg.get(layoutSection, 'ndgImage', None) 
    143170        self.ndgAlt=self.cfg.get(layoutSection, 'ndgAlt','Visit NDG') 
Note: See TracChangeset for help on using the changeset viewer.