The declared length is checked against the body.

highlighted = computed this step

Content-Length declares the body byte count

The header declares 7 body bytes.

Content-Length=7\text{Content-Length}=7
POST Content-LengthThe POST request rows, body rows, field rows, and length check are recomputed from pinned bytes.POST Content-Length - POST /submit body 7 bytes, fields a=1 and b=2sectionnamevaluecheckrequest linemethodPOSTparsedrequest linepath/submitparsedrequest lineversionHTTP/1.1parsedheaderHostforms.exampleexactheaderContent-Typeapplication/x-www-form-urlencodedform encodingheaderContent-Length7declared bytesbodydisplay wordsa=1 ampersand b=2safe display formbodyexact hex613d3126623d32pinned bytesbodybyte length7countedfieldaa=1parsedfieldbb=2parsedcheckContent-Length7declaredcheckbody bytes7recomputedcheckmatchyessame count

The body count is recomputed

The body byte count recomputes to 7.

body bytes=7\text{body bytes}=7
POST Content-LengthThe POST request rows, body rows, field rows, and length check are recomputed from pinned bytes.POST Content-Length - POST /submit body 7 bytes, fields a=1 and b=2sectionnamevaluecheckrequest linemethodPOSTparsedrequest linepath/submitparsedrequest lineversionHTTP/1.1parsedheaderHostforms.exampleexactheaderContent-Typeapplication/x-www-form-urlencodedform encodingheaderContent-Length7declared bytesbodydisplay wordsa=1 ampersand b=2safe display formbodyexact hex613d3126623d32pinned bytesbodybyte length7countedfieldaa=1parsedfieldbb=2parsedcheckContent-Length7declaredcheckbody bytes7recomputedcheckmatchyessame count

The counts match

The check row says yes because the declared count and counted body length are the same.

7=77=7
POST Content-LengthThe POST request rows, body rows, field rows, and length check are recomputed from pinned bytes.POST Content-Length - POST /submit body 7 bytes, fields a=1 and b=2sectionnamevaluecheckrequest linemethodPOSTparsedrequest linepath/submitparsedrequest lineversionHTTP/1.1parsedheaderHostforms.exampleexactheaderContent-Typeapplication/x-www-form-urlencodedform encodingheaderContent-Length7declared bytesbodydisplay wordsa=1 ampersand b=2safe display formbodyexact hex613d3126623d32pinned bytesbodybyte length7countedfieldaa=1parsedfieldbb=2parsedcheckContent-Length7declaredcheckbody bytes7recomputedcheckmatchyessame count

Summary

Content-Length is checked against the actual body bytes.

length check passes\text{length check passes}
POST Content-LengthThe POST request rows, body rows, field rows, and length check are recomputed from pinned bytes.POST Content-Length - POST /submit body 7 bytes, fields a=1 and b=2sectionnamevaluecheckrequest linemethodPOSTparsedrequest linepath/submitparsedrequest lineversionHTTP/1.1parsedheaderHostforms.exampleexactheaderContent-Typeapplication/x-www-form-urlencodedform encodingheaderContent-Length7declared bytesbodydisplay wordsa=1 ampersand b=2safe display formbodyexact hex613d3126623d32pinned bytesbodybyte length7countedfieldaa=1parsedfieldbb=2parsedcheckContent-Length7declaredcheckbody bytes7recomputedcheckmatchyessame count