Fix pyXMLSecurity backend, and add test case.