source: TI12-security/trunk/python/ndg.security.common/ndg/security/common/SessionMgr/SessionMgr_services_types.py @ 2437

Subversion URL: http://proj.badc.rl.ac.uk/svn/ndg/TI12-security/trunk/python/ndg.security.common/ndg/security/common/SessionMgr/SessionMgr_services_types.py@2437
Revision 2437, 13.0 KB checked in by pjkersha, 13 years ago (diff)

ndg.security.server/ndg/security/server/SessionMgr/server-config.tac:

  • soap_disconnect: added call to SessionMgr?.disconnect, added logic for retrieving ID from cert.

used with WS-Security signature.

  • add code to check for useSignatureHandler config param. If this flag is set, get user ID from

cert in WS-Security header

ndg.security.test/ndg/security/test/SessionMgr/sessionMgrProperties.xml,
ndg.security.server/ndg/security/server/SessionMgr/init.py: added "useSignatureHandler" parameter
to properties file elements.

www/html/sessionMgr.wsdl,
ndg.security.server/ndg/security/server/SessionMgr/SessionMgr_services_server.py,
ndg.security.common/ndg/security/common/SessionMgr/SessionMgr_services.py,
ndg.security.common/ndg/security/common/SessionMgr/SessionMgr_services_types.py: removed userCert
argument. - This is not needed as cert chain can be passed in by setting #X509PKIPathv1 for
BinarySecurityToken?.

ndg.security.client/ndg/security/client/ndgSessionClient.py: started on updates from alpha version -
--req-autho flag is now --req-attr

ndg.security.test/ndg/security/test/AttCert/attCertTest.cfg,
ndg.security.test/ndg/security/test/AttCert/attCertTest.cfg: added more tests for signature
verification tests.

ndg.security.test/ndg/security/test/SessionMgr/SessionMgrClientTest.py: removed userCert arg from
disconnect call. It's passed in the signature in the WS-Security header.

ndg.security.common/ndg/security/common/XMLSec.py: fixed bug in applyEnvelopedSignature - removed
incorrect strip call from digest calc:

calcSignedInfoDigestValue = sha(signedInfoC14n).digest()#.strip()


ndg.security.common/ndg/security/common/SessionMgr/init.py: Session Manager client code -
remove refs to "userCert" for disconnect and connect calls. It's passed in the WS-Security header
instead.

ndg.security.common/ndg/security/common/wsSecurity.py: comment - query whitespace strip in
extraction of calculated signature value from message "b64EncSignatureValue".

Line 
1##################################################
2# SessionMgr_services_types.py
3# generated by ZSI.generate.wsdl2python
4##################################################
5
6
7import ZSI
8import ZSI.TCcompound
9from ZSI.schema import LocalElementDeclaration, ElementDeclaration, TypeDefinition, GTD, GED
10from ZSI.generate.pyclass import pyclass_type
11
12##############################
13# targetNamespace
14# urn:ndg:security:sessionMgr
15##############################
16
17class ns0:
18    targetNamespace = "urn:ndg:security:sessionMgr"
19
20    class addUser_Dec(ZSI.TCcompound.ComplexType, ElementDeclaration):
21        literal = "addUser"
22        schema = "urn:ndg:security:sessionMgr"
23        def __init__(self, **kw):
24            ns = ns0.addUser_Dec.schema
25            TClist = [ZSI.TC.String(pname="username", aname="_username", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="passphrase", aname="_passphrase", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded"))]
26            kw["pname"] = ("urn:ndg:security:sessionMgr","addUser")
27            kw["aname"] = "_addUser"
28            self.attribute_typecode_dict = {}
29            ZSI.TCcompound.ComplexType.__init__(self,None,TClist,inorder=0,**kw)
30            class Holder:
31                __metaclass__ = pyclass_type
32                typecode = self
33                def __init__(self):
34                    # pyclass
35                    self._username = None
36                    self._passphrase = None
37                    return
38            Holder.__name__ = "addUser_Holder"
39            self.pyclass = Holder
40
41    class addUserResponse_Dec(ZSI.TCcompound.ComplexType, ElementDeclaration):
42        literal = "addUserResponse"
43        schema = "urn:ndg:security:sessionMgr"
44        def __init__(self, **kw):
45            ns = ns0.addUserResponse_Dec.schema
46            TClist = []
47            kw["pname"] = ("urn:ndg:security:sessionMgr","addUserResponse")
48            kw["aname"] = "_addUserResponse"
49            self.attribute_typecode_dict = {}
50            ZSI.TCcompound.ComplexType.__init__(self,None,TClist,inorder=0,**kw)
51            class Holder:
52                __metaclass__ = pyclass_type
53                typecode = self
54                def __init__(self):
55                    # pyclass
56                    return
57            Holder.__name__ = "addUserResponse_Holder"
58            self.pyclass = Holder
59
60    class connect_Dec(ZSI.TCcompound.ComplexType, ElementDeclaration):
61        literal = "connect"
62        schema = "urn:ndg:security:sessionMgr"
63        def __init__(self, **kw):
64            ns = ns0.connect_Dec.schema
65            TClist = [ZSI.TC.String(pname="username", aname="_username", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="passphrase", aname="_passphrase", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.Boolean(pname="createServerSess", aname="_createServerSess", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.Boolean(pname="getCookie", aname="_getCookie", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded"))]
66            kw["pname"] = ("urn:ndg:security:sessionMgr","connect")
67            kw["aname"] = "_connect"
68            self.attribute_typecode_dict = {}
69            ZSI.TCcompound.ComplexType.__init__(self,None,TClist,inorder=0,**kw)
70            class Holder:
71                __metaclass__ = pyclass_type
72                typecode = self
73                def __init__(self):
74                    # pyclass
75                    self._username = None
76                    self._passphrase = None
77                    self._createServerSess = None
78                    self._getCookie = None
79                    return
80            Holder.__name__ = "connect_Holder"
81            self.pyclass = Holder
82
83    class connectResponse_Dec(ZSI.TCcompound.ComplexType, ElementDeclaration):
84        literal = "connectResponse"
85        schema = "urn:ndg:security:sessionMgr"
86        def __init__(self, **kw):
87            ns = ns0.connectResponse_Dec.schema
88            TClist = [ZSI.TC.String(pname="proxyCert", aname="_proxyCert", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="proxyPriKey", aname="_proxyPriKey", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="userCert", aname="_userCert", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="cookie", aname="_cookie", minOccurs=0, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded"))]
89            kw["pname"] = ("urn:ndg:security:sessionMgr","connectResponse")
90            kw["aname"] = "_connectResponse"
91            self.attribute_typecode_dict = {}
92            ZSI.TCcompound.ComplexType.__init__(self,None,TClist,inorder=0,**kw)
93            class Holder:
94                __metaclass__ = pyclass_type
95                typecode = self
96                def __init__(self):
97                    # pyclass
98                    self._proxyCert = None
99                    self._proxyPriKey = None
100                    self._userCert = None
101                    self._cookie = None
102                    return
103            Holder.__name__ = "connectResponse_Holder"
104            self.pyclass = Holder
105
106    class disconnect_Dec(ZSI.TCcompound.ComplexType, ElementDeclaration):
107        literal = "disconnect"
108        schema = "urn:ndg:security:sessionMgr"
109        def __init__(self, **kw):
110            ns = ns0.disconnect_Dec.schema
111            TClist = [ZSI.TC.String(pname="sessID", aname="_sessID", minOccurs=0, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="encrSessionMgrURI", aname="_encrSessionMgrURI", minOccurs=0, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded"))]
112            kw["pname"] = ("urn:ndg:security:sessionMgr","disconnect")
113            kw["aname"] = "_disconnect"
114            self.attribute_typecode_dict = {}
115            ZSI.TCcompound.ComplexType.__init__(self,None,TClist,inorder=0,**kw)
116            class Holder:
117                __metaclass__ = pyclass_type
118                typecode = self
119                def __init__(self):
120                    # pyclass
121                    self._sessID = None
122                    self._encrSessionMgrURI = None
123                    return
124            Holder.__name__ = "disconnect_Holder"
125            self.pyclass = Holder
126
127    class disconnectResponse_Dec(ZSI.TCcompound.ComplexType, ElementDeclaration):
128        literal = "disconnectResponse"
129        schema = "urn:ndg:security:sessionMgr"
130        def __init__(self, **kw):
131            ns = ns0.disconnectResponse_Dec.schema
132            TClist = []
133            kw["pname"] = ("urn:ndg:security:sessionMgr","disconnectResponse")
134            kw["aname"] = "_disconnectResponse"
135            self.attribute_typecode_dict = {}
136            ZSI.TCcompound.ComplexType.__init__(self,None,TClist,inorder=0,**kw)
137            class Holder:
138                __metaclass__ = pyclass_type
139                typecode = self
140                def __init__(self):
141                    # pyclass
142                    return
143            Holder.__name__ = "disconnectResponse_Holder"
144            self.pyclass = Holder
145
146    class getAttCert_Dec(ZSI.TCcompound.ComplexType, ElementDeclaration):
147        literal = "getAttCert"
148        schema = "urn:ndg:security:sessionMgr"
149        def __init__(self, **kw):
150            ns = ns0.getAttCert_Dec.schema
151            TClist = [ZSI.TC.String(pname="userCert", aname="_userCert", minOccurs=0, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="sessID", aname="_sessID", minOccurs=0, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="encrSessionMgrURI", aname="_encrSessionMgrURI", minOccurs=0, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="attAuthorityURI", aname="_attAuthorityURI", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="attAuthorityCert", aname="_attAuthorityCert", minOccurs=0, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="reqRole", aname="_reqRole", minOccurs=0, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.Boolean(pname="mapFromTrustedHosts", aname="_mapFromTrustedHosts", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.Boolean(pname="rtnExtAttCertList", aname="_rtnExtAttCertList", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="extAttCert", aname="_extAttCert", minOccurs=0, maxOccurs="unbounded", nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="extTrustedHost", aname="_extTrustedHost", minOccurs=0, maxOccurs="unbounded", nillable=False, typed=False, encoded=kw.get("encoded"))]
152            kw["pname"] = ("urn:ndg:security:sessionMgr","getAttCert")
153            kw["aname"] = "_getAttCert"
154            self.attribute_typecode_dict = {}
155            ZSI.TCcompound.ComplexType.__init__(self,None,TClist,inorder=0,**kw)
156            class Holder:
157                __metaclass__ = pyclass_type
158                typecode = self
159                def __init__(self):
160                    # pyclass
161                    self._userCert = None
162                    self._sessID = None
163                    self._encrSessionMgrURI = None
164                    self._attAuthorityURI = None
165                    self._attAuthorityCert = None
166                    self._reqRole = None
167                    self._mapFromTrustedHosts = None
168                    self._rtnExtAttCertList = None
169                    self._extAttCert = []
170                    self._extTrustedHost = []
171                    return
172            Holder.__name__ = "getAttCert_Holder"
173            self.pyclass = Holder
174
175    class getAttCertResponse_Dec(ZSI.TCcompound.ComplexType, ElementDeclaration):
176        literal = "getAttCertResponse"
177        schema = "urn:ndg:security:sessionMgr"
178        def __init__(self, **kw):
179            ns = ns0.getAttCertResponse_Dec.schema
180            TClist = [ZSI.TC.String(pname="attCert", aname="_attCert", minOccurs=0, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="msg", aname="_msg", minOccurs=0, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname="extAttCertOut", aname="_extAttCertOut", minOccurs=0, maxOccurs="unbounded", nillable=False, typed=False, encoded=kw.get("encoded"))]
181            kw["pname"] = ("urn:ndg:security:sessionMgr","getAttCertResponse")
182            kw["aname"] = "_getAttCertResponse"
183            self.attribute_typecode_dict = {}
184            ZSI.TCcompound.ComplexType.__init__(self,None,TClist,inorder=0,**kw)
185            class Holder:
186                __metaclass__ = pyclass_type
187                typecode = self
188                def __init__(self):
189                    # pyclass
190                    self._attCert = None
191                    self._msg = None
192                    self._extAttCertOut = []
193                    return
194            Holder.__name__ = "getAttCertResponse_Holder"
195            self.pyclass = Holder
196
197    class getX509Cert_Dec(ZSI.TCcompound.ComplexType, ElementDeclaration):
198        literal = "getX509Cert"
199        schema = "urn:ndg:security:sessionMgr"
200        def __init__(self, **kw):
201            ns = ns0.getX509Cert_Dec.schema
202            TClist = []
203            kw["pname"] = ("urn:ndg:security:sessionMgr","getX509Cert")
204            kw["aname"] = "_getX509Cert"
205            self.attribute_typecode_dict = {}
206            ZSI.TCcompound.ComplexType.__init__(self,None,TClist,inorder=0,**kw)
207            class Holder:
208                __metaclass__ = pyclass_type
209                typecode = self
210                def __init__(self):
211                    # pyclass
212                    return
213            Holder.__name__ = "getX509Cert_Holder"
214            self.pyclass = Holder
215
216    class getX509CertResponse_Dec(ZSI.TCcompound.ComplexType, ElementDeclaration):
217        literal = "getX509CertResponse"
218        schema = "urn:ndg:security:sessionMgr"
219        def __init__(self, **kw):
220            ns = ns0.getX509CertResponse_Dec.schema
221            TClist = [ZSI.TC.String(pname="x509Cert", aname="_x509Cert", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded"))]
222            kw["pname"] = ("urn:ndg:security:sessionMgr","getX509CertResponse")
223            kw["aname"] = "_getX509CertResponse"
224            self.attribute_typecode_dict = {}
225            ZSI.TCcompound.ComplexType.__init__(self,None,TClist,inorder=0,**kw)
226            class Holder:
227                __metaclass__ = pyclass_type
228                typecode = self
229                def __init__(self):
230                    # pyclass
231                    self._x509Cert = None
232                    return
233            Holder.__name__ = "getX509CertResponse_Holder"
234            self.pyclass = Holder
235
236# end class ns0 (tns: urn:ndg:security:sessionMgr)
Note: See TracBrowser for help on using the repository browser.