-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
None
-
Component/s: None
-
None
-
Needed
When reading a response from the server, if header.messageLength is greater than ismaster.maxMessageSizeBytes a driver MUST raise an error and close the connection.
If this is the first operation run on the server (e.g. the first ismaster command sent on first connection) use a hard coded value of 48MB, switching to ismaster.maxMessageSizeBytes once you have received a valid ismaster response.
Original bug report continues below
---------------------------------------------
The new find() command in MongoDB 3.2 can return documents that are larger then the configured maxBsonObjectSize (16777216 bytes).
Drivers that validate the messageLength header from the server need to adjust their validation accordingly.
I suggest we use the same logic as the server, which is rumored to do:
maxBsonObjectSize + 16K
- depends on
-
MOTOR-179 Drivers must raise an error if response messageLength > ismaster.maxMessageSizeBytes
- Closed
-
GODRIVER-150 Drivers must raise an error if response messageLength > ismaster.maxMessageSizeBytes
- Closed
-
RUST-616 Drivers must raise an error if response messageLength > ismaster.maxMessageSizeBytes
- Closed
- is related to
-
DRIVERS-275 Drivers should check encoded operation size on client side
- Closed
-
CXX-773 Drivers must raise an error if response messageLength > ismaster.maxMessageSizeBytes
- Closed
-
CXX-776 Drivers must raise an error if response messageLength > ismaster.maxMessageSizeBytes
- Closed
-
JAVA-2062 Check for corrupted OP_REPLY message header
- Closed
-
NODE-620 Drivers must raise an error if response messageLength > ismaster.maxMessageSizeBytes
- Closed
-
PHPC-503 Drivers must raise an error if response messageLength > ismaster.maxMessageSizeBytes
- Closed
-
PHPLIB-150 Drivers must raise an error if response messageLength > ismaster.maxMessageSizeBytes
- Closed
-
PYTHON-1029 Drivers must raise an error if response messageLength > ismaster.maxMessageSizeBytes
- Closed
-
RUBY-1076 Drivers must raise an error if response messageLength > ismaster.maxMessageSizeBytes
- Closed
-
CSHARP-1501 Drivers must raise an error if response messageLength > ismaster.maxMessageSizeBytes
- Closed
- related to
-
CDRIVER-1023 Support reading 16mb using the new find commands
- Closed