# requirements-6455-5.2 tool: get_requirements args: {"rfc":6455,"section":"5.2"} --- json --- { "rfc": 6455, "filter": { "section": "5.2", "level": "all" }, "stats": { "total": 8, "byLevel": { "MAY": 1, "MUST": 7 } }, "requirements": [ { "id": "R-5.2-1", "level": "MAY", "text": "The first fragment MAY also be the final fragment.", "section": "5.2", "sectionTitle": "Base Framing Protocol", "fullContext": "FIN: 1 bit Indicates that this is the final fragment in a message. The first fragment MAY also be the final fragment.", "subject": "first fragment", "action": "also be the final fragment" }, { "id": "R-5.2-2", "level": "MUST", "text": "RSV1, RSV2, RSV3: 1 bit each MUST be 0 unless an extension is negotiated that defines meanings for non-zero values.", "section": "5.2", "sectionTitle": "Base Framing Protocol", "fullContext": "RSV1, RSV2, RSV3: 1 bit each MUST be 0 unless an extension is negotiated that defines meanings for non-zero values. If a nonzero value is received and none of the negotiated extensions defines the meaning of such a nonzero value, the receiving endpoint MUST _Fail the WebSocket Connection_.", "subject": "bit", "exception": "an extension is negotiated that defines meanings for non-zero values", "action": "be 0 unless an extension is negotiated that defines meanings for non-zero values" }, { "id": "R-5.2-3", "level": "MUST", "text": "If a nonzero value is received and none of the negotiated extensions defines the meaning of such a nonzero value, the receiving endpoint MUST _Fail the WebSocket Connection_.", "section": "5.2", "sectionTitle": "Base Framing Protocol", "fullContext": "RSV1, RSV2, RSV3: 1 bit each MUST be 0 unless an extension is negotiated that defines meanings for non-zero values. If a nonzero value is received and none of the negotiated extensions defines the meaning of such a nonzero value, the receiving endpoint MUST _Fail the WebSocket Connection_.", "subject": "receiving endpoint", "condition": "a nonzero value is received and none of the negotiated extensions defines the meaning of such a nonzero value", "action": "_Fail the WebSocket Connection_" }, { "id": "R-5.2-4", "level": "MUST", "text": "If an unknown opcode is received, the receiving endpoint MUST _Fail the WebSocket Connection_.", "section": "5.2", "sectionTitle": "Base Framing Protocol", "fullContext": "Opcode: 4 bits Defines the interpretation of the \"Payload data\". If an unknown opcode is received, the receiving endpoint MUST _Fail the WebSocket Connection_. The following values are defined.", "subject": "receiving endpoint", "condition": "an unknown opcode is received", "action": "_Fail the WebSocket Connection_" }, { "id": "R-5.2-5", "level": "MUST", "text": "If 127, the following 8 bytes interpreted as a 64-bit unsigned integer (the most significant bit MUST be 0) are the payload length.", "section": "5.2", "sectionTitle": "Base Framing Protocol", "fullContext": "Payload length: 7 bits, 7+16 bits, or 7+64 bits The length of the \"Payload data\", in bytes: if 0-125, that is the payload length. If 126, the following 2 bytes interpreted as a 16-bit unsigned integer are the payload length. If 127, the following 8 bytes interpreted as a 64-bit unsigned integer (the most significant bit MUST be 0) are the payload length. Multibyte length quantities are expressed in network byte order. Note that in all cases, the minimal number of bytes MUST be used to encode the length, for example, the length of a 124-byte-long string can't be encoded as the sequence 126, 0, 124. The payload length is the length of the \"Extension data\" + the length of the \"Application data\". The length of the \"Extension data\" may be zero, in which case the payload length is the length of the \"Application data\".", "subject": "significant bit", "condition": "127", "action": "be 0) are the payload length" }, { "id": "R-5.2-6", "level": "MUST", "text": "Note that in all cases, the minimal number of bytes MUST be used to encode the length, for example, the length of a 124-byte-long string can't be encoded as the sequence 126, 0, 124.", "section": "5.2", "sectionTitle": "Base Framing Protocol", "fullContext": "Payload length: 7 bits, 7+16 bits, or 7+64 bits The length of the \"Payload data\", in bytes: if 0-125, that is the payload length. If 126, the following 2 bytes interpreted as a 16-bit unsigned integer are the payload length. If 127, the following 8 bytes interpreted as a 64-bit unsigned integer (the most significant bit MUST be 0) are the payload length. Multibyte length quantities are expressed in network byte order. Note that in all cases, the minimal number of bytes MUST be used to encode the length, for example, the length of a 124-byte-long string can't be encoded as the sequence 126, 0, 124. The payload length is the length of the \"Extension data\" + the length of the \"Application data\". The length of the \"Extension data\" may be zero, in which case the payload length is the length of the \"Application data\".", "subject": "bytes", "action": "be used to encode the length" }, { "id": "R-5.2-7", "level": "MUST", "text": "Any extension MUST specify the length of the \"Extension data\", or how that length may be calculated, and how the extension use MUST be negotiated during the opening handshake.", "section": "5.2", "sectionTitle": "Base Framing Protocol", "fullContext": "Extension data: x bytes The \"Extension data\" is 0 bytes unless an extension has been negotiated. Any extension MUST specify the length of the \"Extension data\", or how that length may be calculated, and how the extension use MUST be negotiated during the opening handshake. If present, the \"Extension data\" is included in the total payload length.", "subject": "extension", "action": "specify the length of the \"Extension data\", or how that length may be calculated, and how the extension use MUST be negotiated during the opening handshake" }, { "id": "R-5.2-8", "level": "MUST", "text": "1 bit in length, MUST be 0 unless negotiated otherwise", "section": "5.2", "sectionTitle": "Base Framing Protocol", "fullContext": "frame-rsv1 = %x0 / %x1 ; 1 bit in length, MUST be 0 unless ; negotiated otherwise", "exception": "negotiated otherwise", "action": "be 0 unless negotiated otherwise" } ], "_source": "text", "_sourceNote": "Warning: Parsed from text format. Requirement extraction accuracy may be limited." }