Beispiel #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)
Beispiel #2
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)
Beispiel #3
0
 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)
Beispiel #4
0
 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)