File tree Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -496,7 +496,9 @@ def identify(self, environ):
496
496
# find it
497
497
environ ["post.fieldstorage" ] = post
498
498
# restore wsgi.input incase that is needed
499
- environ ['wsgi.input' ] = StringIO (environ ['s2repoze.body' ])
499
+ # only of s2repoze.body is present
500
+ if 's2repoze.body' in environ :
501
+ environ ['wsgi.input' ] = StringIO (environ ['s2repoze.body' ])
500
502
return {}
501
503
else :
502
504
logger .info ("[sp.identify] --- SAMLResponse ---" )
Original file line number Diff line number Diff line change 24
24
from saml2 .samlp import STATUS_UNKNOWN_ATTR_PROFILE
25
25
from saml2 .samlp import STATUS_UNKNOWN_PRINCIPAL
26
26
from saml2 .samlp import STATUS_UNSUPPORTED_BINDING
27
+ from saml2 .samlp import STATUS_RESPONDER
27
28
28
29
import xmldsig as ds
29
30
import xmlenc as xenc
@@ -158,6 +159,8 @@ class StatusUnknownPrincipal(StatusError):
158
159
class StatusUnsupportedBinding (StatusError ):
159
160
pass
160
161
162
+ class StatusResponder (StatusError ):
163
+ pass
161
164
162
165
STATUSCODE2EXCEPTION = {
163
166
STATUS_VERSION_MISMATCH : StatusVersionMismatch ,
@@ -180,6 +183,7 @@ class StatusUnsupportedBinding(StatusError):
180
183
STATUS_UNKNOWN_ATTR_PROFILE : StatusUnknownAttrProfile ,
181
184
STATUS_UNKNOWN_PRINCIPAL : StatusUnknownPrincipal ,
182
185
STATUS_UNSUPPORTED_BINDING : StatusUnsupportedBinding ,
186
+ STATUS_RESPONDER : StatusResponder ,
183
187
}
184
188
# ---------------------------------------------------------------------------
185
189
You can’t perform that action at this time.
0 commit comments