コード例 #1
0
def test_open_soap_envelope_xxe():
    xml = """<?xml version="1.0"?>
    <!DOCTYPE lolz [
    <!ENTITY lol "lol">
    <!ELEMENT lolz (#PCDATA)>
    <!ENTITY lol1 "&lol;&lol;&lol;&lol;&lol;&lol;&lol;&lol;&lol;&lol;">
    ]>
    <lolz>&lol1;</lolz>
    """
    with raises(soap.XmlParseError):
        soap.open_soap_envelope(xml)
コード例 #2
0
ファイル: test_43_soap.py プロジェクト: Amli/pysaml2
def test_open_soap_envelope_xxe():
    xml = """<?xml version="1.0"?>
    <!DOCTYPE lolz [
    <!ENTITY lol "lol">
    <!ELEMENT lolz (#PCDATA)>
    <!ENTITY lol1 "&lol;&lol;&lol;&lol;&lol;&lol;&lol;&lol;&lol;&lol;">
    ]>
    <lolz>&lol1;</lolz>
    """
    with raises(soap.XmlParseError):
        soap.open_soap_envelope(xml)
コード例 #3
0
ファイル: entity.py プロジェクト: gbel/pysaml2
 def unpack_soap_message(self, text):
     """
     Picks out the parts of the SOAP message, body and headers apart
     :param text: The SOAP message
     :return: A dictionary with two keys "body"/"header"
     """
     return open_soap_envelope(text)
コード例 #4
0
ファイル: entity.py プロジェクト: sigmunau/pysaml2
 def unpack_soap_message(self, text):
     """
     Picks out the parts of the SOAP message, body and headers apart
     :param text: The SOAP message
     :return: A dictionary with two keys "body"/"header"
     """
     return open_soap_envelope(text)