S90-19 practice question 11 of 15

Which of the following statements is true?

Full set: 83 questions
Answer options
A: When the maxOccurs attribute in an XML schema element is not specified it creates a security risk because attackers can specify this element multiple times.
B: When numeric ranges within an XML schema are not specified it creates a security risk because attackers can introduce very large numeric values within the message data.
C: When the xsd:any element is used within an XML schema it can introduce a security risk because it allows attackers to extend the schema.
D: All of above. Correct answer
Correct Answer:
D. All of above.
Explanation

All listed statements describe valid security risks stemming from insufficiently constrained XML schemas. A secure schema should be explicit and restrictive.
A. While the default for maxOccurs is 1, the principle of failing to define an explicit, reasonable upper bound (e.g., using maxOccurs="unbounded") creates a Denial-of-Service (DoS) vulnerability known as coercive parsing.
B. Not constraining numeric types with range restrictions allows attackers to submit extremely large values, potentially causing integer overflows or resource exhaustion in the processing application.
C. The xsd:any wildcard element bypasses strict schema validation for a portion of the XML document, creating a vector for content spoofing or injection of malicious, unexpected data. Therefore, all three represent significant security concerns.

Why Incorrect

A. This option is incomplete. While it describes a valid security principle, it omits the equally critical risks outlined in options B and C.
B. This option is incomplete. It correctly identifies the risk of unspecified numeric ranges but ignores the vulnerabilities described in options A and C.
C. This option is incomplete. The risk associated with xsd:any is valid, but this choice neglects the important security risks mentioned in A and B.

References

1. National Institute of Standards and Technology (NIST) Special Publication 800-95, "Guide to Secure Web Services":

Section 4.1.1, "Oversized XML Payload", discusses the threat of DoS attacks using excessively large messages, which relates to the risks in options A and B where element occurrences or numeric values are not bounded.

Section 4.2.1, "XML Schema Validation", states, "The schema should be restrictive enough to prevent common attacks, such as buffer overflows... and content spoofing." This directly supports the principles in B (preventing overflows) and C (preventing content spoofing).

2. Tripunitara, M. V., & van Oorschot, P. C. (2011). "A Taxonomy of XML Schema-Hardening." ACM Transactions on Information and System Security (TISSEC), 14(3), Article 24.

Section 3.1, "Wildcards", explicitly identifies xs:any as a security concern because it allows "arbitrary elements to appear," which corresponds to the risk described in option C.

Section 3.3, "Occurrence Constraints", discusses how unbounded occurrence constraints (e.g., maxOccurs="unbounded") can be exploited for DoS attacks, supporting the security principle behind option A.

DOI: https://doi.org/10.1145/2019599.2019605

3. Jensen, M., Gruschka, N., & Luttenberger, N. (2009). "The Impact of XML Schema on Web Service Security." 2009 IEEE International Conference on Web Services.

Section III.B, "Attacks on XML Parser", describes how "an attacker can try to exhaust the resources of the parser by sending a message with a huge number of attributes or nested elements," which is the threat mitigated by properly constraining maxOccurs (Option A).

DOI: https://doi.org/10.1109/ICWS.2009.135

Scroll to Top