summaryrefslogtreecommitdiff
path: root/example
diff options
context:
space:
mode:
authorRoland Hedberg <roland.hedberg@adm.umu.se>2015-03-31 09:56:30 +0200
committerRoland Hedberg <roland.hedberg@adm.umu.se>2015-03-31 09:56:30 +0200
commit8bd652682dc94e18d57473fb95c0211374122907 (patch)
treea752c824a41ec37d274ccb96b83e3811840f303b /example
parente075717fa8ca17361cb79058f6640b1a71b6ad52 (diff)
downloadpysaml2-8bd652682dc94e18d57473fb95c0211374122907.tar.gz
Spelling error. Added and extra parameter check.
Diffstat (limited to 'example')
-rwxr-xr-xexample/idp2/idp.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/example/idp2/idp.py b/example/idp2/idp.py
index 08c0e0c0..5d2a46ed 100755
--- a/example/idp2/idp.py
+++ b/example/idp2/idp.py
@@ -132,8 +132,13 @@ class Service(object):
else:
# saml_msg may also contain Signature and SigAlg
if "Signature" in saml_msg:
- kwargs = {"signature": saml_msg["signature"],
- "sigalg": saml_msg["SigAlg"]}
+ try:
+ kwargs = {"signature": saml_msg["Signature"],
+ "sigalg": saml_msg["SigAlg"]}
+ except KeyError:
+ resp = BadRequest(
+ 'Signature Algorithm specification is missing')
+ return resp(self.environ, self.start_response)
else:
kwargs = {}
try: