Skip to content

Conversation

bcopeland
Copy link
Contributor

Hi, I'm using pysaml2 to generate assertions to test an SP and found these when generating signed authn responses.

If caller asked for a signed response, we would return None.
Return the response from self.sign() instead.
The signing code expects a flattened list of tuples, not a list
which contains a list of tuples.  For example, in my case I had:

to_sign = [('urn:oasis:names:tc:SAML:2.0:assertion:Assertion', 'id-2d44a290a77c9fe7b50899eea96aa183'), [('urn:oasis:names:tc:SAML:2.0:protocol:Response', 'id-7416bafb9df777c1c1151b6f1ce471bb')]]

Fixes:

  File "/usr/local/lib/python2.7/dist-packages/pysaml2-1.0.2-py2.7.egg/saml2/ent
ity.py", line 458, in _response
    return self.sign(response, to_sign=to_sign)
  File "/usr/local/lib/python2.7/dist-packages/pysaml2-1.0.2-py2.7.egg/saml2/ent
ity.py", line 347, in sign
    return signed_instance_factory(msg, self.sec, to_sign)
  File "/usr/local/lib/python2.7/dist-packages/pysaml2-1.0.2-py2.7.egg/saml2/sig
ver.py", line 264, in signed_instance_factory
    for (node_name, nodeid) in elements_to_sign:
ValueError: need more than 1 value to unpack
rohe pushed a commit that referenced this pull request Jun 26, 2013
bugs in entity.py for signed responses
@rohe rohe merged commit 06bb368 into IdentityPython:master Jun 26, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants