The function is_lasso_ecp_enabled() in saml2idp.py was testing for a
specific lasso version. That has proved problematic because we've had
too many "unofficial" versions floating around and sometimes the
version check produces the wrong result.
A better test is to test for the presence of a symbol in the lasso
library we know will only be there with full ECP support.
Now we test for the presence of ECP_ERROR_MISSING_AUTHN_REQUEST.
Ticket: 167
Signed-off-by: John Dennis <jdennis@redhat.com>
Reviewed-by: Patrick Uiterwijk <puiterwijk@redhat.com>
def is_lasso_ecp_enabled():
- # Full ECP support appeared in lasso version 2.4.2
- return lasso.checkVersion(2, 4, 2, lasso.CHECK_VERSION_NUMERIC)
+ # Look for an exported symbol we know was added with ECP support
+ return 'ECP_ERROR_MISSING_AUTHN_REQUEST' in dir(lasso)
class SSO_SOAP(AuthenticateRequest):