def parse_values(self, xml):
    try:
        root = etree.fromstring(xml)
    except Exception as e:
        raise InvalidXML(('Unable to load XML: %s' % e.message))
    parser_dispatcher = self.get_parser_dispatcher()
    self.parse_entity_id(root)
    try:
        idp_sso_desc = root.xpath(MetadataExtractor.XPATHS['idp_sso_descriptor'], namespaces=MetadataExtractor.NAMESPACES)[0]
    except IndexError as e:
        raise InvalidXML('Unable to parse IdP SSO Descriptor Node')
    for node in idp_sso_desc.getchildren():
        tag = self.extract_tag(node.tag)
        parser = parser_dispatcher[tag]
        parser(node)
def parse_values(self, xml):
    try:
        root = etree.fromstring(xml)
    except Exception as e:
        raise InvalidXML(('Unable to load XML: %s' % e.message))
    parser_dispatcher = self.get_parser_dispatcher()
    self.parse_entity_id(root)
    try:
        idp_sso_desc = root.xpath(MetadataExtractor.XPATHS['idp_sso_descriptor'], namespaces=MetadataExtractor.NAMESPACES)[0]
    except IndexError as e:
        raise InvalidXML('Unable to parse IdP SSO Descriptor Node')
    for node in idp_sso_desc.getchildren():
        tag = self.extract_tag(node.tag)
        parser = parser_dispatcher[tag]
        parser(node)