تحديد مشاكل وقت التشغيل وحلّها في سياسة XMLThreatProtection

أنت الآن بصدد الاطّلاع على مستندات Apigee Edge.
انتقِل إلى مستندات Apigee X.
info

ExecutionFailed

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition policy_name:
        Execution failed. Reason: error_description at line line_num
        (possibly around char char_num)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: Premature end of document while parsing at line 5(possibly  around char 0)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

أنواع الأخطاء والأسباب المحتملة

يمكن أن تعرض سياسة XMLThreatProtection العديد من الأنواع المختلفة من أخطاء ExecutionFailed. يسرد الجدول أدناه الأنواع المختلفة من الأخطاء وأسبابها المحتملة:

خطأ السبب
ElementNameExceeded تم تجاوز الحد الأقصى لطول السلسلة المسموح به في علامة XML.
ChildCountExceeded تم تجاوز الحد الأقصى لعدد العناصر الفرعية المسموح بها في حمولة XML.
NodeDepthExceeded تم تجاوز الحدّ الأقصى لعمق عناصر XML المسموح به في حمولة XML.
AttributeCountExceeded تم تجاوز الحد الأقصى لعدد السمات في عنصر واحد.
AttributeNameExceeded تم تجاوز الحدّ الأقصى المسموح به لطول اسم السمة.
AttributeValueExceeded تم تجاوز الحد الأقصى المسموح به لطول قيمة السمة.
TextExceeded تم تجاوز الحد الأقصى لطول النص المسموح به.
CommentExceeded تم تجاوز الحد الأقصى لطول التعليق المسموح به.
PIDataExceeded تم تجاوز طول البيانات المسموح به لتعليمات المعالجة.
PITargetExceeded تم تجاوز طول اسم تعليمات العملية.
NSURIExceeded تم تجاوز طول عنوان URL لمساحة الاسم.
NSPrefixExceeded تم تجاوز طول بادئة مساحة الاسم.
NSCountExceeded تم تجاوز عدد مساحات الأسماء المستخدَمة في عنصر واحد.
حمولة XML غير صالحة حمولة XML المدخلة غير صالحة.

ElementNameExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

تعرض الزيارات في وقت التشغيل رمز الاستجابة 500 مع الخطأ التالي:

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition policy_name:
        Execution failed. reason: XMLThreatProtection stepDefinition policy_name:
        Element name length exceeded num at line line_num(possibly
        around char char_num)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Element name length exceeded 5 at line 1(possibly around char 9)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كانت حمولة الإدخال المحدّدة بواسطة العنصر <Source> في السياسة تحتوي على عناصر XML تتجاوز الحد الأقصى للطول المحدّد في العنصر <Element> ضمن العنصر <NameLimits>.

على سبيل المثال، إذا تم تحديد العنصر <Element> على أنّه 5 في سياسة XMLThreatProtection، ولكن حمولة الإدخال تحتوي على عنصر يتضمّن أكثر من 5 أحرف، سيتم عرض هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر ورقم الحرف المحتمل في حمولة الإدخال التي تم تجاوز طول العنصر فيها.

    على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XML-Threat-Protection-1, ورقم السطر في الحمولة هو 1 ورقم الحرف المحتمل هو 9.

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Element name
    length exceeded 5 at line 1(possibly around char 9)
    
  2. افحص السياسة التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ولاحِظ القيمة المحدّدة في العنصر <Element>.

    على سبيل المثال، في سياسة XMLThreatProtection التالية، تم ضبط <Element> على 5:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>5</Element>
            <Attribute>5</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>5</NodeDepth>
            <AttributeCountPerElement>2</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>15</Text>
            <Attribute>10</Attribute>
            <NamespaceURI>10</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>10</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) في حمولة الإدخال وتحقّق مما إذا كان طول العنصر في هذا السطر أكبر من القيمة المحدّدة للعنصر <Element> (المحدّد في الخطوة 2). إذا تجاوز طول العنصر هذه القيمة، سيكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <company>
      <name>Google</name>
      <country>USA</country>
    </company>
    

    تحتوي حمولة XML الموضّحة أعلاه على عنصر جذر اسمه company في السطر 1 ويتألف من 7 أحرف. بما أنّ طول العنصر أكبر من 5 (القيمة المحدّدة للعنصر <Element>)، سيظهر لك الخطأ التالي:

    XML-Threat-Protection-1: Execution failed. reason: XMLThreatProtection stepDefinition
    XML-Threat-Protection-1: Element name length exceeded 5 at line 1(possibly around char 9)
    

الدقة

إذا كانت سياسة XMLThreadProtection تهدف إلى الحماية من الحمولات التي تتضمّن أسماء عناصر تتجاوز القيمة المحدّدة، من المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا تبيّن لك أنّه يمكن تحديد عناصر أطول في الحمولة بدون أي عواقب، عدِّل <Element> إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك السماح بعناصر يصل طولها إلى 10، عدِّل سياسة XMLThreatProtection على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>5</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>5</NodeDepth>
        <AttributeCountPerElement>2</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>15</Text>
        <Attribute>10</Attribute>
        <NamespaceURI>10</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>10</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

ChildCountExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition policy_name:
        Execution failed. reason: XMLThreatProtection stepDefinition policy_name:
        Children count exceeded num at line  num(possibly
        around char num)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Children count exceeded 3 at line 5(possibly around char 89)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كان حمولة رسالة الإدخال المحدّدة بواسطة العنصر <Source> تحتوي على عنصر XML يحتوي على عناصر فرعية أكثر من القيمة المحدّدة في العنصر <ChildCount> من السياسة.

على سبيل المثال، إذا كان العنصر <ChildCount> هو 3، ولكن حمولة XML المدخلة تحتوي على عنصر يتضمّن أكثر من 3 عناصر فرعية، سيظهر هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم تجاوز عدد الإدخالات فيه. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XML-Threat-Protection-1 ورقم السطر في الحمولة هو 5:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Children
    count exceeded 3 at line 5(possibly around char 89)"
    
  2. افحص السياسة التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ولاحِظ القيمة المحدّدة في العنصر <ChildCount>.

    في مثال السياسة التالي، تم ضبط <ChildCount> على 3(يُرجى العِلم أنّ التعليقات والعناصر المضمّنة وغيرها يتم احتسابها ضمن هذا الحد):

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>5</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>5</NodeDepth>
            <AttributeCountPerElement>2</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>15</Text>
            <Attribute>10</Attribute>
            <NamespaceURI>10</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>10</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) في حمولة الإدخال وتحقّق مما إذا كان عدد العناصر الفرعية (بما في ذلك جميع التعليقات وما إلى ذلك) في الحمولة أكبر من القيمة المحدّدة للعنصر <ChildCount> (المحدّد في الخطوة 2). إذا كان عدد العناصر الفرعية يتجاوز عدد العناصر الفرعية، يكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <movie>
      <title>Jurassic Park</title>
      <language>English</language>
      <country>USA</country>
      <director>Steven Spielberg</director>
    </movie>
    

    في حمولة بيانات XML الموضّحة أعلاه، يحتوي السطر 5 على عنصر ثانوي رابع <director> للعنصر الجذر <movie>. بما أنّ عدد العناصر الثانوية في حمولة XML المُدخَلة أكبر من 3 (القيمة المحدّدة للعنصر <ChildCount>)، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Children
    count exceeded 3 at line 5(possibly around char 89)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من حمولات تحتوي على عدد عناصر فرعية يتجاوز حدًا معيّنًا، فمن المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتّخاذ أي إجراء إضافي.

ومع ذلك، إذا تبيّن لك أنّه يمكن تضمين عدد أكبر من العناصر الفرعية (بما في ذلك التعليقات وما إلى ذلك) في الحمولة بدون أي عواقب، يمكنك تعديل <ChildCount>إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك السماح بما يصل إلى 10 عناصر فرعية، عدِّل سياسة XMLThreatProtection على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>5</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>5</NodeDepth>
        <AttributeCountPerElement>2</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">10</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>15</Text>
        <Attribute>10</Attribute>
        <NamespaceURI>10</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>10</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

NodeDepthExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]:
        Execution failed. reason: XMLThreatProtection stepDefinition [policy_name]:
        Node depth exceeded [num] at line [num](possibly around
        char [num])",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Node depth exceeded 5 at line 6(possibly around char 110)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كانت حمولة رسالة الإدخال المحدّدة بواسطة العنصر <Source> تحتوي على مستند XML يتجاوز فيه التسلسل الهرمي للعُقد العدد المحدّد في العنصر <NodeDepth> من سياسة XMLThreatProtection.

على سبيل المثال، إذا تم تحديد العنصر <NodeDepth> على أنّه 4 في السياسة، ولكن حمولة الإدخال تحتوي على عمق عقدة يتجاوز 4، سيتم عرض هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم تجاوز عمق العقدة فيه. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XML-Threat-Protection-1 ورقم السطر في الحمولة هو 6:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Node depth
    exceeded 5 at line 6(possibly around char 109)
    
  2. افحص سياسة XMLThreatProtection التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ولاحِظ القيمة المحدّدة في العنصر <NodeDepth>.

    في مثال سياسة XMLThreatProtection التالي، تم ضبط <NodeDepth> على 5:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>5</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>5</NodeDepth>
            <AttributeCountPerElement>2</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>15</Text>
            <Attribute>10</Attribute>
            <NamespaceURI>10</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>10</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) لحِمل الإدخال وتحقّق مما إذا كان عمق العقدة المحدّد هناك يحتوي على عدد أكبر من العدد المحدّد في العنصر <NodeDepth> (المحدّد في الخطوة 2). إذا كان مستوى العناصر الثانوية في XML يتجاوز العدد، يكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <hellos>
       <hello1>
           <wave1>
                <wave2>
                    <wave3>
                        <wave4>
                           <wave5>wave</wave5>
                        </wave4>
                    </wave3>
                </wave2>
           </wave1>
       </hello1>
       <hello2>world2</hello2>
       <hello3>world3</hello3>
       <hello4>world4</hello4>
       <hello5>world5</hello5>
       <hello6>world6</hello6>
    </hellos>
    

    يحتوي حمولة XML المعروضة أعلاه في السطر 6 على عمق عقدة يبلغ 6.بما أنّ عمق العقدة أكبر من 5 (القيمة المحدّدة للعنصر <NodeDepth>)، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Node depth
    exceeded 5 at line 6(possibly around char 109)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من حمولات ذات حدّ معيّن لعمق العقدة، من المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا تبيّن لك أنّه يمكن السماح بعمق أكبر للعُقدة، عدِّل <NodeDepth>إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك السماح بعمق عقدة يصل إلى 10، يمكنك تعديل السياسة على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>5</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>2</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>15</Text>
        <Attribute>10</Attribute>
        <NamespaceURI>10</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>10</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

AttributeCountExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]:
        Execution failed. reason: XMLThreatProtection stepDefinition [policy_name]:
        Attribute count exceeded [num] at line [num](possibly around
        char [num])",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Attribute count exceeded 2 at line 3(possibly around char 105)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كان حمولة رسالة الإدخال المحدّدة بواسطة عنصر <Source> في سياسة XMLThreatProtection يحتوي على مستند XML يتجاوز فيه عدد سمات عنصر واحد العدد المحدّد في عنصر <AttributeCountPerElement> في السياسة.

على سبيل المثال، إذا تم تحديد العنصر <AttributeCountPerElement> على أنّه 2 في سياسة XMLThreatProtection، ولكن حمولة الإدخال تحتوي على عنصر يتضمّن أكثر من سمتَين، سيتم عرض هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم تجاوز عدد السمات فيه. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XMLThreat-Protection-1 ورقم السطر في الحمولة هو 3:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Attribute
    count exceeded 2 at line 3(possibly around char 105)
    
  2. افحص السياسة التي تعذّر تنفيذها (المحدّدة في الخطوة 1)، ولاحِظ القيمة المحدّدة في العنصر <AttributeCountPerElement>.

    في مثال السياسة التالي، تم ضبط <AttributeCountPerElement> على 2:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>5</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>2</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>15</Text>
            <Attribute>10</Attribute>
            <NamespaceURI>10</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>10</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) من حمولة الإدخال وتحقّق مما إذا كان عدد السمات المحدّدة يتجاوز العدد المحدّد في العنصر <AttributeCountPerElementh> (المحدّد في الخطوة 2). إذا كان عدد السمات يتجاوز العدد، يكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <?xml version="1.0" encoding="UTF-8"?>
    <bookstore>
      <book category="cooking" cuisine="Indian" lang="en">
        <title>Easy Indian Cooking</title>
        <author>Suneeta</author>
        <year>2004</year>
        <price>300.00</price>
      </book>
    </bookstore>
    

    تحتوي حمولة بيانات XML الموضّحة أعلاه في السطر 3 على عنصر يتضمّن ثلاث سمات. بما أنّ عدد السمات أكبر من 2 (القيمة المحدّدة للعنصر <AttributeCountPerElement>)، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Attribute
    count exceeded 2 at line 3(possibly around char 105)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من حمولات تتجاوز عددًا معيّنًا من السمات، من المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا تبيّن لك أنّه يمكن السماح بعدد أكبر من السمات، عدِّل <AttributeCountPerElement> إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك السماح بعدد من السمات لكل عنصر يصل إلى 5، عدِّل السياسة على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>5</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>5</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>15</Text>
        <Attribute>10</Attribute>
        <NamespaceURI>10</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>10</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

AttributeNameExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]:
        Execution failed. reason: XMLThreatProtection stepDefinition [policy_name]:
        Attribute name length exceeded [num] at line [num](possibly around char [num])",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Attribute name length exceeded 5 at line 3(possibly around char 105)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كان حمولة رسالة الإدخال المحدّدة بواسطة العنصر <Source> في سياسة XMLThreatProtection تحتوي على مستند XML يتجاوز فيه اسم السمة عدد الأحرف المحدّد في العنصر الثانوي <Attribute> للعنصر <NameLimits> في السياسة.

على سبيل المثال، إذا تم تحديد العنصر <Attribute> على أنّه 5 في السياسة، ولكن حمولة الإدخال تحتوي على اسم سمة يتضمّن أكثر من 5 أحرف، سيتم عرض هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم تجاوز طول اسم السمة فيه. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XML-Threat-Protection-1 ورقم السطر في الحمولة هو 3:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Attribute
    name length exceeded 5 at line 3(possibly around char 105)
    
  2. افحص السياسة التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ولاحِظ القيمة المحدّدة في العنصر <Attribute>

    في مثال سياسة XMLThreatProtection التالي، تم ضبط <Attribute> على 5:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>5</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>2</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>15</Text>
            <Attribute>10</Attribute>
            <NamespaceURI>10</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>10</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) في حمولة الإدخال وتحقّق مما إذا كان طول السمة المحدّدة يتضمّن أحرفًا أكثر من العدد المحدّد في العنصر <Attribute> (المحدّد في الخطوة 2). إذا كان عدد الأحرف يتجاوز قيمة السمة، سيكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <?xml version="1.0" encoding="UTF-8"?>
    <bookstore>
      <book category="cooking" cuisine="Indian" lang="en">
        <title>Easy Indian Cooking</title>
        <author>Suneeta</author>
        <year>2004</year>
        <price>300.00</price>
      </book>
    </bookstore>
    

    يحتوي حمولة XML المعروضة أعلاه في السطر 3 على سمتَين category وcuisine يبلغ طول اسميهما 8 و7 أحرف على التوالي. بما أنّ طول اسم السمة أكبر من 5 (القيمة المحدّدة للعنصر <Attribute>)، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Attribute
    name length exceeded 5 at line 3(possibly around char 105)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من الحمولات التي تتجاوز طول اسم سمة معيّن، من المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا قرّرت السماح بطول أطول لاسم السمة، يمكنك تعديل <Attribute> إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك استخدام أسماء سمات تصل إلى 10 أحرف، عدِّل السياسة على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>10</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>5</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>15</Text>
        <Attribute>10</Attribute>
        <NamespaceURI>10</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>10</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

AttributeValueExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]: Execution failed. reason: XMLThreatProtection stepDefinition [policy_name]:  Attribute value length exceeded [num] at line [num](possibly around char [num])",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Attribute value length exceeded 10 at line 3(possibly around char 111)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كانت حمولة رسالة الإدخال المحدّدة بواسطة العنصر <Source> في السياسة تحتوي على مستند XML تتجاوز فيه قيمة السمة عدد الأحرف المحدّد في العنصر الثانوي <Attribute> للعنصر <ValueLimits>.

على سبيل المثال، إذا تم تحديد العنصر <Attribute> على أنّه 10 في سياسة XMLThreatProtection، ولكن حمولة الإدخال تحتوي على قيمة سمة تتضمّن أكثر من 10 أحرف، سيتم عرض هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم تجاوز عدد السمات فيه. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XML-Threat-Protection-1 ورقم السطر في الحمولة هو 3:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Attribute
    value length exceeded 10 at line 3(possibly around char 111)
    
  2. افحص السياسة التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ولاحِظ القيمة المحدّدة في العنصر الفرعي <Attribute> للعنصر <ValueLimits>.

    في مثال سياسة XMLThreatProtection التالي، تم ضبط <Attribute> على 10:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>5</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>2</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>15</Text>
            <Attribute>10</Attribute>
            <NamespaceURI>10</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>10</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) في حمولة الإدخال وتحقّق مما إذا كان طول قيمة السمة المحدّدة هناك يتضمّن أحرفًا أكثر من العدد المحدّد في العنصر <Attribute> (المحدّد في الخطوة 2). إذا كان عدد الأحرف يتجاوز قيمة السمة، سيكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <?xml version="1.0" encoding="UTF-8"?>
    <bookstore>
      <book category="cooking" cuisine="South Indian" lang="en">
        <title>Easy Indian Cooking</title>
        <author>Suneeta</author>
        <year>2004</year>
        <price>300.00</price>
      </book>
    </bookstore>
    

    يحتوي حمولة XML المعروضة أعلاه في السطر 3 على سمة (cuisine) بطول قيمة يبلغ 12 حرفًا. بما أنّ طول قيمة السمة أكبر من 10 (القيمة المحدّدة للعنصر <Attribute>)، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Attribute
    value length exceeded 10 at line 3(possibly around char 111)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من الحمولات التي تتجاوز طول قيمة سمة معيّنة، من المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا قرّرت السماح بقيم أطول للسمات، يمكنك تعديل العنصر الفرعي <Attribute> للعنصر <ValueLimits> إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك تحديد قيم تصل إلى 15 حرفًا، عدِّل السياسة على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>10</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>5</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>15</Text>
        <Attribute>15</Attribute>
        <NamespaceURI>10</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>10</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

TextExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]: Execution failed. reason: XMLThreatProtection stepDefinition [policy_name]:  Text length exceeded [num] at line [num](possibly around char [num])",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Text length exceeded 15 at line 4(possibly around char 66)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }

السبب

يحدث هذا الخطأ إذا كانت حمولة رسالة الإدخال المحدّدة بواسطة العنصر <Source> في سياسة XMLThreatProtection تحتوي على مستند XML يتجاوز فيه طول نص أحد العناصر عدد الأحرف المحدّد في العنصر الفرعي <Text> للعنصر <ValueLimits> في السياسة.

على سبيل المثال، إذا تم تحديد العنصر <Text> على أنّه 15 في السياسة، ولكن حمولة الإدخال تحتوي على نص يتضمّن أكثر من 15 حرفًا، سيتم عرض هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم تجاوز عدد السمات فيه. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XML-Threat-Protection-1 ورقم السطر في الحمولة هو 4:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Text length
    exceeded 15 at line 4(possibly around char 66)
    
  2. افحص السياسة التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ولاحِظ القيمة المحدّدة في العنصر الفرعي <Text> للعنصر <ValueLimits>.

    في مثال سياسة XMLThreatProtection التالي، تم ضبط <Text> على 15:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>5</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>2</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>15</Text>
            <Attribute>10</Attribute>
            <NamespaceURI>10</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>10</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) في حمولة الإدخال وتحقّق مما إذا كان طول قيمة السمة المحدّدة هناك يتضمّن أحرفًا أكثر من العدد المحدّد في العنصر <Text> (المحدّد في الخطوة 2). إذا كان عدد الأحرف يتجاوز قيمة السمة، سيكون ذلك هو سبب الخطأ.

    <food>
      <name>Veg Sandwich</name>
      <price>$5.95</price>
      <description>Vegetarian Sandwich with onions, tomatoes and lettuce</description>
      <calories>650</calories>
    </food>
    

    يحتوي حمولة XML المعروضة أعلاه في السطر 4 على نص بطول 53 حرفًا. بما أنّ طول قيمة السمة أكبر من 15 (القيمة المحدّدة للعنصر <Text>)، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Text length
    exceeded 15 at line 4(possibly around char 66)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من الحمولات التي تتجاوز طول نص معيّن، من المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا قرّرت السماح بأطوال نص أطول، يمكنك تعديل <Text>العنصر الفرعي للعنصر <ValueLimits> إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك الحصول على قيم سمات تصل إلى 60 حرفًا، عدِّل السياسة على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>10</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>5</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>60</Text>
        <Attribute>15</Attribute>
        <NamespaceURI>10</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>10</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

CommentExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]:
        Execution failed. reason: XMLThreatProtection stepDefinition [policy_name]:
        Comment length exceeded [num] at line [num](possibly around char
        [num])",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Comment length exceeded 10 at line 2(possibly around char 48)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كانت حمولة رسالة الإدخال المحدّدة بواسطة العنصر <Source> في سياسة XMLThreatProtection تحتوي على مستند XML يتجاوز فيه طول التعليق عدد الأحرف المحدّد في العنصر الثانوي <Comment> للعنصر <ValueLimits> في السياسة.

على سبيل المثال، إذا تم تحديد العنصر <Comment> على أنّه 10 في السياسة، ولكن حمولة الإدخال تتضمّن تعليقًا يتألف من أكثر من 10 أحرف، سيظهر هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم تجاوز طول التعليق فيه. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XML-Threat-Protection-1 ورقم السطر في الحمولة هو 2:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Comment length exceeded 10 at line 2(possibly around char 48)
    
  2. افحص السياسة التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ولاحِظ القيمة المحدّدة في العنصر الفرعي <Comment> للعنصر <ValueLimits>.

    في مثال سياسة XMLThreatProtection التالي، تم ضبط <Comment> على 10:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>5</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>2</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>15</Text>
            <Attribute>10</Attribute>
            <NamespaceURI>10</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>10</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (الذي تم تحديده في الخطوة 1) في حمولة الإدخال وتحقّق مما إذا كان طول التعليق المحدّد يتضمّن أحرفًا أكثر من العدد المحدّد في العنصر <Comment> (الذي تم تحديده في الخطوة 2). إذا كان عدد الأحرف يتجاوز قيمة السمة، سيكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <food>
      <!--This is somewhat a long comment-->
      <name>Veg Sandwich</name>
      <price>$5.95</price>
      <description>Vegetarian Sandwich with onions, tomatoes and lettuce</description>
      <calories>650</calories>
    </food>
    

    يحتوي حمولة XML المعروضة أعلاه في السطر 2 على تعليق يبلغ طول قيمته 31 حرفًا. بما أنّ طول التعليق أكبر من 10 (القيمة المحدّدة للعنصر <Comment>)، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Comment length
    exceeded 10 at line 2(possibly around char 48)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من الحمولات التي تتجاوز طول تعليق معيّن، من المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا قرّرت السماح بتعليق أطول، يمكنك تعديل <Comment>العنصر الفرعي للعنصر<ValueLimits> إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك تحديد قيم تصل إلى 40 حرفًا، عدِّل السياسة على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>10</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>5</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>15</Text>
        <Attribute>15</Attribute>
        <NamespaceURI>10</NamespaceURI>
        <Comment>40</Comment>
        <ProcessingInstructionData>10</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

PIDataExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]:
        Execution failed. reason: XMLThreatProtection stepDefinition [policy_name]:
        Processing Instruction data length exceeded [num] at line
        [num](possibly around char [num])",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Processing Instruction data length exceeded 30 at line 2(possibly around char 109)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كان حمولة رسالة الإدخال المحدّدة بواسطة العنصر <Source> في سياسة XMLThreatProtection يحتوي على مستند XML يتجاوز فيه أمر معالجة البيانات عدد الأحرف المحدّد في العنصر الفرعي <ProcessingInstructionData> للعنصر <ValueLimits> في السياسة.

على سبيل المثال، إذا تم تحديد العنصر <ProcessingInstructionData> على أنّه 10 في سياسة XMLThreatProtection، ولكن حمولة الإدخال تتضمّن تعليمات معالجة بأكثر من 10 أحرف، سيتم عرض هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم تجاوز طول تعليمات المعالجة فيه. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XML-Threat-Protection-1 ورقم السطر في الحمولة هو 2:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Processing
    Instruction data length exceeded 30 at line 2(possibly around char 109)
    
  2. افحص السياسة التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ولاحِظ القيمة المحدّدة في العنصر الفرعي <ProcessingInstructionData> للعنصر <ValueLimits> .

    في مثال سياسة XMLThreatProtection التالي، تم ضبط <ProcessingInstructionData> على 30:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>5</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>2</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>15</Text>
            <Attribute>10</Attribute>
            <NamespaceURI>10</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>30</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) من حمولة الإدخال وتحقّق مما إذا كان طول بيانات تعليمات المعالجة المحدّدة هناك يحتوي على أحرف أكثر من الرقم المحدّد في العنصر <ProcessingInstructionData> (المحدّد في الخطوة 2). إذا كان عدد الأحرف يتجاوز بيانات تعليمات المعالجة، سيكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <?xml-stylesheet type="text/xsl" href="mobilephones.xsl"?>
    <mobilephones>
      <mobilephone>
          <name>iPhone</name>
          <price>$600</price>
      </mobilephone>
      <mobilephone>
          <name>Samsung</name>
          <price>$500</price>
      </mobilephone>
    </mobilephones>
    

    تحتوي حمولة XML الموضّحة أعلاه في السطر 1 على عنصر بيانات تعليمات المعالجة (type="text/xsl" href="mobilephones.xsl"?)بطول 40 حرفًا.). وبما أنّ هذا الطول أكبر من 30 (القيمة المحدّدة للعنصر <ProcessingInstructionData>)، يظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Processing
    Instruction data length exceeded 30 at line 2(possibly around char 109)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من الحمولات التي تتجاوز طول بيانات تعليمات معالجة معيّنًا، من المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا قرّرت السماح بعناصر بيانات تعليمات المعالجة الأطول، عدِّل العنصر الفرعي <ProcessingInstructionData> للعنصر <ValueLimits> إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك الحصول على تعليمات معالجة بيانات يصل طولها إلى 50 حرفًا، عدِّل السياسة على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>10</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>5</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>15</Text>
        <Attribute>15</Attribute>
        <NamespaceURI>10</NamespaceURI>
        <Comment>40</Comment>
        <ProcessingInstructionData>50</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

PITargetExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]:
        Execution failed. reason: XMLThreatProtection stepDefinition [policy_name]:
        Processing Instruction target length exceeded [num] at line [num](possibly around
        char [num])",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Processing Instruction target length exceeded 10 at line 2(possibly around char 114)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كانت حمولة رسالة الإدخال المحدّدة بواسطة العنصر <Source> في سياسة XMLThreatProtection تحتوي على مستند XML يتجاوز فيه هدف تعليمات المعالجة عدد الأحرف المحدّد في العنصر الفرعي <ProcessingInstructionTarget> للعنصر <NameLimits> في السياسة.

على سبيل المثال، إذا تم تحديد العنصر <ProcessingInstructionTarget> على أنّه 10 في سياسة XMLThreatProtection، ولكن حمولة الإدخال تحتوي على هدف تعليمات معالجة يتضمّن أكثر من 10 أحرف، سيتم عرض هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم فيه تجاوز عدد أهداف تعليمات المعالجة. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XML-Threat-Protection-1 ورقم السطر في الحمولة هو 1:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Processing
    Instruction target length exceeded 10 at line 2(possibly around char 114)
    
  2. افحص سياسة XMLThreatProtection التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ودوِّن القيمة المحدّدة في العنصر الفرعي <ProcessingInstructionTarget> للعنصر <NameLimits>.

    في مثال سياسة XMLThreatProtection التالي، تم ضبط <ProcessingInstructionTarget> على 10:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>10</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>5</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>20</Text>
            <Attribute>15</Attribute>
            <NamespaceURI>40</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>30</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) من حمولة الإدخال وتحقّق مما إذا كان طول هدف تعليمات المعالجة المحدّد هناك يحتوي على أحرف أكثر من الرقم المحدّد في العنصر <ProcessingInstructionTarget> (المحدّد في الخطوة 2). إذا كان عدد الأحرف يتجاوز الحدّ الأقصى للحجم المستهدف، يكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <?xml-stylesheet type="text/xsl" href="mobilephones.xsl"?>
    <mobilephones>
      <mobilephone>
          <name>iPhone</name>
          <price>$600</price>
      </mobilephone>
      <mobilephone>
          <name>Samsung</name>
          <price>$500</price>
      </mobilephone>
    </mobilephones>
    

    يحتوي حمولة XML المعروضة أعلاه في السطر 2 على اسم هدف تعليمات المعالجة "xml-stylesheet"" بطول 14 حرفًا. بما أنّ اسم هدف تعليمات المعالجة أطول من 10 (القيمة المحدّدة للعنصر <ProcessingInstructionTarget>)، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Processing
    Instruction target length exceeded 10 at line 2(possibly around char 114)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من الحمولات التي تتجاوز طولًا محدّدًا لهدف تعليمات المعالجة، من المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا تبيّن لك أنّ هدف تعليمات المعالجة يمكن أن يكون أطول، عدِّل <ProcessingInstructionTarget>العنصر الفرعي للعنصر <NameLimits> إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك الحصول على استهدافات لتعليمات المعالجة تصل إلى 25 حرفًا، يمكنك تعديل السياسة على النحو التالي:

  <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
  <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>5</Attribute>
        <NamespacePrefix>15</NamespacePrefix>
    <ProcessingInstructionTarget>25</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>2</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>15</Text>
        <Attribute>10</Attribute>
        <NamespaceURI>40</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>10</ProcessingInstructionData>
    </ValueLimits>
  </XMLThreatProtection>

NSURIExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]: Execution failed. reason: XMLThreatProtection stepDefinition [policy_name]:  Namespace uri length length exceeded [num] at line [num](possibly around char [num])",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Namespace uri length exceeded 10 at line 2(possibly around char 97)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كانت حمولة رسالة الإدخال المحدّدة بواسطة العنصر <Source> في سياسة XMLThreatProtection تحتوي على مستند XML يتجاوز فيه معرّف الموارد المنتظم لمساحة الاسم عدد الأحرف المحدّد في العنصر الفرعي <NamespaceURI> للعنصر <ValueLimits> في السياسة.

على سبيل المثال، إذا تم تحديد العنصر <NamespaceURI> على أنّه 10 في السياسة، ولكن حمولة الإدخال تحتوي على معرّف موارد منتظم (URI) لمساحة الاسم يتضمّن أكثر من 10 أحرف، سيتم عرض هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم تجاوز طول معرّف الموارد المنتظم لمساحة الاسم فيه. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XML-Threat-Protection-1 ورقم السطر في الحمولة هو 2:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Namespace
    uri length exceeded 10 at line 2(possibly around char 97)
    
  2. افحص السياسة التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ولاحظ القيمة المحدّدة في العنصر الفرعي <NamespaceURI> للعنصر <ValueLimits>.

    في مثال سياسة XMLThreatProtection التالي، تم ضبط <NamespaceURI> على 10:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>5</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>2</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>15</Text>
            <Attribute>10</Attribute>
            <NamespaceURI>10</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>10</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) من حمولة الإدخال وتحقّق ممّا إذا كان طول معرّف الموارد المنتظم (URI) لمساحة الاسم المحدّد هناك يحتوي على أحرف أكثر من العدد المحدّد في العنصر <NamespaceURI> (المحدّد في الخطوة 2). إذا كان عدد الأحرف يتجاوز طول معرّف الموارد المنتظم لمساحة الاسم، سيكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <?xml version = "1.0" encoding = "UTF-8"?>
      <profile:user xmlns:profile = "www.google.com/profile">
      <profile:name>Rama Krishna</profile:name>
      <profile:company>Google</profile:company>
      <profile:phone>(91) 9876543210</profile:phone>
    </profile:user>
    

    يحتوي حمولة XML المعروضة أعلاه في السطر 2 على معرّف الموارد المنتظم (URI) لمساحة الاسم، www.google.com/profile، ويبلغ طوله 22 حرفًا. بما أنّ طول معرّف الموارد المنتظم لمساحة الاسم أكبر من 10 (القيمة المحدّدة للعنصر <NamespaceURI>)، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Namespace
    uri length exceeded 10 at line 2(possibly around char 99)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من الحمولات التي تجاوزت طولًا معيّنًا لمعرّف الموارد المنتظم لمساحة الاسم، من المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا قرّرت السماح بمعرّف موارد منتظم (URI) أطول لمساحة الاسم، يمكنك تعديل العنصر الفرعي <NamespaceURI> للعنصر <ValueLimits> إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك الحصول على أطوال عناوين URI لمساحة الاسم تصل إلى 30 حرفًا، عدِّل السياسة على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>5</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>2</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>15</Text>
        <Attribute>10</Attribute>
        <NamespaceURI>30</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>10</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

NSPrefixExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]:
        Execution failed. reason: XMLThreatProtection stepDefinition [policy_name]:
        Namespace prefix length exceeded [num] at line [num](possibly
        around char [num])",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Namespace prefix length exceeded 10 at line 2(possibly around char 105)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كانت حمولة رسالة الإدخال المحدّدة بواسطة العنصر <Source> تحتوي على مستند XML يتجاوز فيه البادئة لمساحة الاسم عدد الأحرف المحدّد في العنصر الفرعي <NamespacePrefix> للعنصر <NameLimits> في السياسة.

على سبيل المثال، إذا تم تحديد العنصر <NamespacePrefix> على أنّه 10 في سياسة XMLThreatProtection، ولكن حمولة الإدخال تحتوي على بادئة مساحة اسم تتضمّن أكثر من 10 أحرف، سيتم عرض هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم تجاوز طول بادئة معرّف الموارد المنتظم لمساحة الاسم فيه. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XML-Threat-Protection-1 ورقم السطر في الحمولة هو 2:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Namespace
    prefix length exceeded 10 at line 2(possibly around char 105)
    
  2. افحص السياسة التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ولاحظ القيمة المحدّدة في العنصر الفرعي <NamespacePrefix> للعنصر <NameLimits>.

    في مثال سياسة XMLThreatProtection التالي، تم ضبط <NamespacePrefix> على 10:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>10</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>5</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>20</Text>
            <Attribute>15</Attribute>
            <NamespaceURI>40</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>30</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) في حمولة الإدخال وتحقّق ممّا إذا كان طول بادئة مساحة الاسم المحدّدة هناك يحتوي على أحرف أكثر من العدد المحدّد في العنصر <NamespacePrefix> (المحدّد في الخطوة 2). إذا كان عدد الأحرف يتجاوز الحدّ الأقصى المسموح به لبادئة مساحة الاسم، سيكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <?xml version = "1.0" encoding = "UTF-8"?>
    <userprofile:user xmlns:userprofile = "www.googlecom/profile">
      <userprofile:name>Rama Krishna</userprofile:name>
      <userprofile:company>Google</userprofile:company>
      <userprofile:phone>(011) 123-4567</userprofile:phone>
    </userprofile:user>
    

    يحتوي حمولة XML المعروضة أعلاه في السطر 2 على بادئة مساحة اسم userprofile بطول 11 حرفًا. بما أنّ طول بادئة معرّف الموارد المنتظم لمساحة الاسم أكبر من 10 (القيمة المحدّدة للعنصر <NamespacePrefix>)، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Namespace
    prefix length exceeded 10 at line 2(possibly around char 105)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من الحمولات التي تتجاوز طول بادئة معيّنًا لمعرّف الموارد المنتظم (URI) لمساحة الاسم، من المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا قرّرت السماح باستخدام بادئة أطول لمعرّف الموارد المنتظم لمساحة الاسم، يمكنك تعديل العنصر الفرعي <NamespacePrefix> للعنصر <NameLimits> إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك الحصول على أطوال بادئة لمعرّف الموارد المنتظم للمساحة الاسمية تصل إلى 15 حرفًا، عدِّل السياسة على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>5</Attribute>
        <NamespacePrefix>15</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>2</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>15</Text>
        <Attribute>10</Attribute>
        <NamespaceURI>40</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>10</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

NSCountExceeded

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]:
        Execution failed. reason: XMLThreatProtection stepDefinition [policy_name]:
        Namespace count exceeded [num] at line [num](possibly around char [num])",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed. reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Namespace count exceeded 3 at line 2(possibly around char 234)",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كانت حمولة رسالة الإدخال المحدّدة بواسطة عنصر <Source> في سياسة XMLThreatProtection تحتوي على مستند XML يتجاوز فيه عدد مساحات الأسماء المستخدَمة في عنصر واحد العدد المحدّد في العنصر الفرعي <NamespaceCountPerElement> للعنصر <StructureLimits> في السياسة.

على سبيل المثال، إذا تم تحديد العنصر <NamespaceCountPerElement> على أنّه 3 في السياسة، ولكن حمولة الإدخال تحتوي على عنصر يتضمّن أكثر من 3 مساحات أسماء، سيتم عرض هذا الخطأ.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم سياسة XMLThreatProtection ورقم السطر الذي تم تجاوز عدد مساحات الأسماء فيه. على سبيل المثال، في رسالة الخطأ التالية، اسم السياسة هو XMLThreat-Protection-1 ورقم السطر في الحمولة هو 2:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Namespace count
    exceeded 3 at line 2(possibly around char 234)
    
  2. افحص السياسة التي تعذّر تنفيذها (المحدّدة في الخطوة 1) ولاحظ القيمة المحدّدة في العنصر الفرعي <NamespaceCountPerElement> للعنصر <StructureLimits>.

    في مثال سياسة XMLThreatProtection التالي، تم ضبط <NamespaceCountPerElement> على 3:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>10</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>request</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>5</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>20</Text>
            <Attribute>15</Attribute>
            <NamespaceURI>40</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>30</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    
  3. افحص رقم السطر المحدّد (المحدّد في الخطوة 1) من حمولة الإدخال وتحقّق مما إذا كان عدد مساحات الأسماء المحدّدة هناك لعنصر واحد أكبر من العدد المحدّد في العنصر <NamespaceCountPerElement> (المحدّد في الخطوة 2). إذا كان عدد مساحات الأسماء يتجاوز الحدّ الأقصى المسموح به لعدد مساحات الأسماء لكل عنصر، سيكون ذلك هو سبب الخطأ.

    في ما يلي مثال على حمولة الإدخال:

    <?xml version = "1.0" encoding = "UTF-8"?>
    <hellos xmlns:h="https://www.w3schools.com/greeting1" xmlns:a="https://www.w3schools.com/greeting2" xmlns:b="https://www.w3schols.com/greeting3" xmlns:c="https://www.w3schools.com/greeting4">
        <a:hello1>world1</a:hello1>
        <b:hello2>world2</b:hello2>
        <c:hello2>world2</c:hello2>
        <h:hello2>world2</h:hello2>
    </hellos>
    

    تحتوي حمولة XML المعروضة أعلاه في السطر 2 على أكثر من 3 مساحات أسماء. بما أنّ عدد مساحات الأسماء أكبر من 3 (القيمة المحدّدة للعنصر <NamespaceCountPerElement>)، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: XMLThreatProtection stepDefinition XML-Threat-Protection-1: Namespace
    count exceeded 3 at line 2(possibly around char 234)
    

الدقة

إذا كانت سياسة XMLThreatProtection تهدف إلى الحماية من الحمولات التي تتجاوز عددًا معيّنًا من مساحات الأسماء في عنصر واحد، فمن المتوقّع ظهور رسالة الخطأ. في هذه الحالة، ليس عليك اتخاذ أي إجراء إضافي.

ومع ذلك، إذا تبيّن لك أنّه يمكن السماح بعدد أكبر من مساحات الأسماء، عدِّل العنصر الفرعي <NamespaceCountPerElement> للعنصر <StructureLimits> إلى قيمة مناسبة استنادًا إلى متطلباتك.

على سبيل المثال، إذا كنت تعتقد أنّه يمكنك الحصول على ما يصل إلى 5 مساحات أسماء في عنصر واحد، عدِّل السياسة على النحو التالي:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>10</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>5</AttributeCountPerElement>
        <NamespaceCountPerElement>5</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>20</Text>
        <Attribute>15</Attribute>
        <NamespaceURI>40</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>30</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

InvalidXMLPayload

رمز الخطأ

steps.xmlthreatprotection.ExecutionFailed

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition [policy_name]:
        Execution failed. Reason: [error_description]",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Execution failed. reason: Syntax error while parsing XML prologue",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.ExecutionFailed"
        }
    }
}

السبب

يحدث هذا الخطأ إذا لم يكن حمولة رسالة الإدخال المحدّدة بواسطة العنصر <Source> في سياسة XMLProtectionPolicy مستند XML صالحًا.

التشخيص

  1. افحص رسالة الخطأ لتحديد اسم السياسة التي حدث فيها الخطأ. في المثال التالي، اسم السياسة هو XML-Threat-Protection-1.

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: Syntax error while parsing XML prologue
    
  2. افحص حمولة الإدخال وتحقَّق مما إذا كان مستند XML الذي تم تمريره في الحمولة هو مستند XML سليم التنسيق أم لا.

    في ما يلي مثال على حمولة الإدخال:

    <?xml version="1.0" encoding="UTF-8"?>
    <bookstore>
      <book category="cooking">
        <title lang="en">Easy Indian Cooking</title>
        <author>Suneeta</author>
        <year>2004</year>
        <price>300.00</price>
      </book>
    <bookstore>
    

    في حمولة XML الموضّحة أعلاه، لا يغلق السطر 9 العنصر الجذر بشكل صحيح لأنّ / غير متوفّر. بما أنّ هذا ليس XML صحيح التنسيق، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Execution failed.
    reason: Syntax error while parsing XML prologue
    

الدقة

تأكَّد من تمرير حمولة XML صالحة إلى أي خادم وكيل لواجهة برمجة التطبيقات يتضمّن سياسة XMLThreatProtection.

لتصحيح الخطأ الوارد في المثال أعلاه، عدِّل حمولة XML للإدخال على النحو التالي:

<?xml version="1.0" encoding="UTF-8"?>
<bookstore>
  <book category="cooking">
    <title lang="en">Easy Indian Cooking
    <author>Suneeta</author>
    <year>2004</year>
    <price>300.00</price>
  </book>
</bookstore>

SourceUnavailable

رمز الخطأ

steps.xmlthreatprotection.SourceUnavailable

نص رد الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition[policy_name]: Source[var_name] is not available"
        "detail": {
            "errorcode": "steps.xmlthreatprotection.SourceUnavailable"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "XMLThreatProtection stepDefinition XML-Threat-Protection-1:
        Source requests is not available",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.SourceUnavailable"
        }
    }
}

السبب

يحدث هذا الخطأ إذا كان المتغيّر message المحدّد في العنصر <Source> من سياسة XMLThreatProtection إما:

  • خارج النطاق (غير متوفّر في المسار المحدّد الذي يتم فيه تنفيذ السياسة)
  • ليست إحدى القيم الصالحة request أو response أو message

على سبيل المثال، يحدث هذا الخطأ إذا تم ضبط العنصر <Source> في السياسة على متغيّر غير متوفّر في المسار الذي يتم فيه تنفيذ السياسة.

التشخيص

  1. حدِّد اسم سياسة XMLThreatProtection واسم متغيّر المصدر من رسالة الخطأ. على سبيل المثال، في رسالة الخطأ التالية، يكون اسم سياسة XMLThreatProtection هو XML-Threat-Protection-1، ويكون العنصر المتغيّر Source هو requests:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Source requests
    is not available
    
  2. افحص سياسة XMLThreatProtection التي تعذّر تنفيذها وتحقّق من القيمة المحدّدة للعنصر <Source> الذي تم تحديده في الخطوة 1.

    في مثال سياسة XMLThreatProtection التالي، تم ضبط العنصر <Source> على requests.

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>10</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>requests</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>5</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>20</Text>
            <Attribute>15</Attribute>
            <NamespaceURI>40</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>30</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    

    القيم الصالحة للعنصر <Source> هي request أو response أو message.. وبما أنّ requests ليست قيمة صالحة ولا تتوفّر في المسار الذي يتم فيه تنفيذ السياسة، سيظهر لك الخطأ التالي:

    XMLThreatProtection stepDefinition XML-Threat-Protection-1: Source requests
    is not available
    

الدقة

تأكَّد من أنّ المتغيّر الذي تم ضبطه في العنصر <Source> من سياسة XMLThreatProtection التي تعذّر تنفيذها تم ضبطه على request أو response أو message، وأنّه متوفّر في التدفق الذي يتم فيه تنفيذ السياسة.

لتصحيح نموذج السياسة الموضّح أعلاه، يمكنك تعديل العنصر <Source> لاستخدام المتغيّر request ، لأنّه متوفّر في مسار الطلب:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>10</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>request</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>5</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>20</Text>
        <Attribute>15</Attribute>
        <NamespaceURI>40</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>30</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>

NonMessageVariable

رمز الخطأ

steps.xmlthreatprotection.NonMessageVariable

نص رد الخطأ

{
    "fault": {
        "faultstring": "Variable var_name does not resolve to a Message"
        "detail": {
            "errorcode": "steps.xmlthreatprotection.NonMessageVariable"
        }
    }
}

مثال على نص ردّ الخطأ

{
    "fault": {
        "faultstring": "Variable message.content does not resolve to a Message",
        "detail": {
            "errorcode": "steps.xmlthreatprotection.NonMessageVariable"
        }
    }
}

السبب

يحدث هذا الخطأ إذا تم ضبط العنصر <Source> في سياسة XMLThreatProtection على متغيّر ليس من النوع Message.

تمثّل متغيرات نوع الرسالة طلبات واستجابات HTTP كاملة. تكون متغيّرات التدفق المضمّنة في Apigee Edge request وresponse وmessage من النوع Message. لمزيد من المعلومات عن متغيّرات الرسائل، يُرجى الاطّلاع على مرجع المتغيّرات.

التشخيص

  1. حدِّد اسم المتغيّر الذي يتم تحويله إلى نوع متغيّر الرسالة من رسالة الخطأ. على سبيل المثال، في رسالة الخطأ التالية، اسم المتغير هو message.content

    Variable message.content does not resolve to a Message
    
  2. افحص جميع سياسات XMLThreadProtection في خادم API الوكيل الذي حدث فيه الخطأ، وحدِّد سياسة XMLThreadProtection المحدّدة التي تم فيها تحديد العنصر <Source> باسم المتغيّر المحدّد في الخطوة 1 أعلاه.

    في مثال سياسة XMLThreatProtection التالي، تم ضبط <Source> على message.content:

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
        <DisplayName>XML Threat Protection-1</DisplayName>
        <Properties/>
        <NameLimits>
            <Element>10</Element>
            <Attribute>10</Attribute>
            <NamespacePrefix>10</NamespacePrefix>
            <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
        </NameLimits>
        <Source>message.content</Source>
        <StructureLimits>
            <NodeDepth>10</NodeDepth>
            <AttributeCountPerElement>5</AttributeCountPerElement>
            <NamespaceCountPerElement>3</NamespaceCountPerElement>
            <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
        </StructureLimits>
        <ValueLimits>
            <Text>20</Text>
            <Attribute>15</Attribute>
            <NamespaceURI>40</NamespaceURI>
            <Comment>10</Comment>
            <ProcessingInstructionData>30</ProcessingInstructionData>
        </ValueLimits>
    </XMLThreatProtection>
    

    بما أنّ المتغيّر message.content ليس من النوع Message، سيظهر لك الخطأ التالي:

    Variable message.content does not resolve to a Message
    

الدقة

تأكَّد من ضبط العنصر <Source> في سياسة XMLThreatProtection التي تعذّر تنفيذها على متغيّر تدفق من النوع Message المتوفّر في التدفق الذي يتم فيه تنفيذ السياسة.

لتصحيح السياسة، يمكنك تعديل العنصر <Source> لتحديد متغيّر من النوع Message. على سبيل المثال، في XMLThreatProtection غير الناجح، يمكنك تحديد العنصر <Source> على النحو التالي: message:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<XMLThreatProtection async="false" continueOnError="false" enabled="true" name="XML-Threat-Protection-1">
    <DisplayName>XML Threat Protection-1</DisplayName>
    <Properties/>
    <NameLimits>
        <Element>10</Element>
        <Attribute>10</Attribute>
        <NamespacePrefix>10</NamespacePrefix>
        <ProcessingInstructionTarget>10</ProcessingInstructionTarget>
    </NameLimits>
    <Source>message</Source>
    <StructureLimits>
        <NodeDepth>10</NodeDepth>
        <AttributeCountPerElement>5</AttributeCountPerElement>
        <NamespaceCountPerElement>3</NamespaceCountPerElement>
        <ChildCount includeComment="true" includeElement="true" includeProcessingInstruction="true" includeText="true">3</ChildCount>
    </StructureLimits>
    <ValueLimits>
        <Text>20</Text>
        <Attribute>15</Attribute>
        <NamespaceURI>40</NamespaceURI>
        <Comment>10</Comment>
        <ProcessingInstructionData>30</ProcessingInstructionData>
    </ValueLimits>
</XMLThreatProtection>