AI-generated audit finding — this issue was opened from an automated security/correctness audit. It has not been triaged by a human yet; verify the reasoning, reproducibility, and severity before acting on it.
Low: Slic Initialize parameter dictionary has no cardinality cap
Affected code:
Description:
Initialize / InitializeAck frame bodies are capped at 16,383 bytes by MaxControlFrameBodySize (added in #4516), and the individual parameter values that we care about are range-checked (MaxStreamFrameSize, InitialStreamWindowSize ≥ 1 KB; IdleTimeout ≠ 0). However:
- There is no explicit cap on the number of entries in the parameter dictionary. Within the 16 KB body, a peer can pack a large number of small unknown parameters — each is decoded into the
IDictionary<ParameterKey, IList<byte>> and then ignored by the switch (the // Ignore unsupported parameter branch at line 960 has no default: rejection).
- Duplicate parameter keys are not explicitly rejected by
DecodeParameters; handling depends on how the underlying Slice dictionary decoder reacts to duplicates, and that contract is not asserted at this call site.
Impact: Low — bounded by the 16 KB frame cap. This is defense-in-depth hardening, not an exploitable DoS.
Recommendation:
- Add an explicit cap on the number of parameters accepted in
DecodeParameters (e.g. 32) and throw InvalidDataException beyond it.
- Either reject unknown parameter keys outright, or document that unknown keys are silently ignored and bound their count as above.
- Assert (and test) behavior on duplicate keys — either reject or define a deterministic resolution.
Related: #4409, #4410 (other peer-parameter range checks), #4516 (body-size cap), #3317 (umbrella).
Source report: Slic security review against HTTP/2 CVE classes (CVE-2019-9512..9518, CVE-2023-44487). Companion findings with higher sensitivity are tracked privately in icerpc/icerpc-csharp-audit.
Low: Slic Initialize parameter dictionary has no cardinality cap
Affected code:
DecodeParametersMaxControlFrameBodySize = 16,383Description:
Initialize/InitializeAckframe bodies are capped at 16,383 bytes byMaxControlFrameBodySize(added in #4516), and the individual parameter values that we care about are range-checked (MaxStreamFrameSize,InitialStreamWindowSize≥ 1 KB;IdleTimeout≠ 0). However:IDictionary<ParameterKey, IList<byte>>and then ignored by theswitch(the// Ignore unsupported parameterbranch at line 960 has nodefault:rejection).DecodeParameters; handling depends on how the underlying Slice dictionary decoder reacts to duplicates, and that contract is not asserted at this call site.Impact: Low — bounded by the 16 KB frame cap. This is defense-in-depth hardening, not an exploitable DoS.
Recommendation:
DecodeParameters(e.g. 32) and throwInvalidDataExceptionbeyond it.Related: #4409, #4410 (other peer-parameter range checks), #4516 (body-size cap), #3317 (umbrella).
Source report: Slic security review against HTTP/2 CVE classes (CVE-2019-9512..9518, CVE-2023-44487). Companion findings with higher sensitivity are tracked privately in icerpc/icerpc-csharp-audit.