Length check in the constructor throwing ArgumentException when violated; a per-label 63-character regex check exists in source but is commented out and not enforced.
Outcome
Rejects domain strings that violate the RFC1035 overall length limit before a Question object is created.
Confidence
Verified
Source
SAIF.Framework.DNS\Question.cs
BR-003: DnsType must be a defined, non-None enum value¶
Field
Value
Statement
The DnsType supplied to the public Question constructor must be a defined enum value other than None.
Trigger
Question public constructor invoked with a DnsType argument.
Enforcement
Enum.IsDefined check in the constructor throwing ArgumentOutOfRangeException when violated.
Outcome
Rejects invalid or undefined query types before a Question object is created.
Confidence
Verified
Source
SAIF.Framework.DNS\Question.cs
BR-004: DnsClass must be a defined, non-None enum value¶
Field
Value
Statement
The DnsClass supplied to the public Question constructor must be a defined enum value other than None.
Trigger
Question public constructor invoked with a DnsClass argument.
Enforcement
Enum.IsDefined check in the constructor throwing ArgumentOutOfRangeException when violated.
Outcome
Rejects invalid or undefined query classes before a Question object is created.
Confidence
Verified
Source
SAIF.Framework.DNS\Question.cs
BR-005: UDP requests are retried up to two additional times before failing¶
Field
Value
Statement
A DNS UDP request is retried up to 2 additional times before the operation is considered failed.
Trigger
No matching-id response is received within the 1-second receive timeout on a given attempt.
Enforcement
Resolver.UdpTransfer retry loop, bounded by the constant _udpRetryAttempts (2).
Outcome
After exhausting all attempts, NoResponseException is thrown to the caller.
Confidence
Verified
Source
SAIF.Framework.DNS\Resolver.cs
BR-006: UDP replies are only accepted when the transaction id matches¶
Field
Value
Statement
A returned UDP datagram is only accepted as a valid reply if its 2-byte transaction id matches the request's stamped id.
Trigger
Every UDP receive performed inside Resolver.UdpTransfer.
Enforcement
Byte-level comparison of responseMessage[0..1] against requestMessage[0..1].
Outcome
Mismatched or unrelated packets are ignored, which implicitly drives the retry loop (see BR-005).
Rule enforcement in this library is entirely input-validation and transport-retry logic; no persistence, workflow, or authorization rules apply, consistent with this library performing no database or security interactions.
The per-label 63-character domain validation described in Question.cs exists only as a commented-out Regex.IsMatch call and is not currently enforced; whether this was an intentional relaxation or an oversight is unknown.**