Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 31 - 40 of 43 for SMB2_HEADER_LENGTH (0.09 seconds)

The search processing time has exceeded the limit. The displayed results may be partial.

  1. src/main/java/jcifs/internal/smb2/notify/Smb2ChangeNotifyRequest.java

        }
    
        /**
         * {@inheritDoc}
         *
         * @see jcifs.internal.CommonServerMessageBlockRequest#size()
         */
        @Override
        public int size() {
            return size8(Smb2Constants.SMB2_HEADER_LENGTH + 32);
        }
    
        /**
         * {@inheritDoc}
         *
         * @see jcifs.internal.smb2.ServerMessageBlock2#writeBytesWireFormat(byte[], int)
         */
        @Override
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Sat Aug 16 01:32:48 GMT 2025
    - 5.5K bytes
    - Click Count (0)
  2. src/test/java/jcifs/internal/smb2/create/Smb2CreateRequestTest.java

        @DisplayName("Test size calculation without create contexts")
        void testSizeWithoutCreateContexts() {
            request = new Smb2CreateRequest(mockConfig, "test.txt");
    
            int expectedSize = Smb2Constants.SMB2_HEADER_LENGTH + 56;
            int nameLen = 2 * "test.txt".length();
            expectedSize += ((nameLen + 7) / 8) * 8; // size8(nameLen)
            expectedSize = ((expectedSize + 7) / 8) * 8; // size8(size)
    
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Thu Aug 14 07:14:38 GMT 2025
    - 18.6K bytes
    - Click Count (0)
  3. src/main/java/jcifs/internal/smb2/ServerMessageBlock2.java

            } else {
                // 4 reserved
                SMBUtil.writeInt4(this.treeId, dst, dstIndex + 36);
            }
            SMBUtil.writeInt8(this.sessionId, dst, dstIndex + 40);
    
            return Smb2Constants.SMB2_HEADER_LENGTH;
        }
    
        /**
         * Reads the SMB2 header from the wire format.
         *
         * @param buffer the buffer to read from
         * @param bufferIndex the starting position in the buffer
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Sun Aug 31 08:00:57 GMT 2025
    - 24K bytes
    - Click Count (0)
  4. src/main/java/jcifs/internal/smb2/info/Smb2QueryDirectoryRequest.java

        }
    
        /**
         * {@inheritDoc}
         *
         * @see jcifs.internal.CommonServerMessageBlockRequest#size()
         */
        @Override
        public int size() {
            return size8(Smb2Constants.SMB2_HEADER_LENGTH + 32 + (this.fileName != null ? 2 * this.fileName.length() : 0));
        }
    
        /**
         * {@inheritDoc}
         *
         * @see jcifs.internal.smb2.ServerMessageBlock2#writeBytesWireFormat(byte[], int)
         */
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Sat Aug 16 01:32:48 GMT 2025
    - 7.3K bytes
    - Click Count (0)
  5. src/main/java/jcifs/internal/smb2/nego/Smb2NegotiateRequest.java

        }
    
        /**
         * {@inheritDoc}
         *
         * @see jcifs.internal.CommonServerMessageBlockRequest#size()
         */
        @Override
        public int size() {
            int size = Smb2Constants.SMB2_HEADER_LENGTH + 36 + size8(2 * this.dialects.length, 4);
            if (this.negotiateContexts != null) {
                for (final NegotiateContextRequest ncr : this.negotiateContexts) {
                    size += 8 + size8(ncr.size());
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Sun Aug 31 08:00:57 GMT 2025
    - 9.3K bytes
    - Click Count (0)
  6. src/main/java/jcifs/internal/smb2/ioctl/Smb2IoctlRequest.java

        }
    
        /**
         * {@inheritDoc}
         *
         * @see jcifs.internal.CommonServerMessageBlockRequest#size()
         */
        @Override
        public int size() {
            final int size = Smb2Constants.SMB2_HEADER_LENGTH + 56;
            int dataLength = 0;
            if (this.inputData != null) {
                dataLength += this.inputData.size();
            }
            if (this.outputData != null) {
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Sat Aug 16 01:32:48 GMT 2025
    - 9.4K bytes
    - Click Count (0)
  7. src/test/java/jcifs/internal/smb2/io/Smb2FlushRequestTest.java

            assertEquals(mockConfig, responseConfig);
        }
    
        @Test
        @DisplayName("size should return correct message size")
        void testSize() {
            int expectedSize = Smb2Constants.SMB2_HEADER_LENGTH + 24;
            // size8 method rounds up to 8-byte boundary
            int expectedAlignedSize = (expectedSize + 7) & ~7;
    
            assertEquals(expectedAlignedSize, request.size());
        }
    
        @Test
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Thu Aug 14 05:31:44 GMT 2025
    - 11.5K bytes
    - Click Count (0)
  8. src/test/java/jcifs/internal/smb2/ioctl/Smb2IoctlResponseTest.java

            byte[] buf = new byte[header.length + 10];
            System.arraycopy(header, 0, buf, 0, header.length);
            // Write invalid structure size 50 at body start
            SMBUtil.writeInt2(50, buf, Smb2Constants.SMB2_HEADER_LENGTH);
    
            BaseConfiguration config = new BaseConfiguration(true);
            Smb2IoctlResponse resp = new Smb2IoctlResponse(config);
            assertThrows(SMBProtocolDecodingException.class, () -> resp.decode(buf, 0));
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Thu Aug 14 05:31:44 GMT 2025
    - 10.9K bytes
    - Click Count (0)
  9. src/main/java/jcifs/internal/smb2/create/Smb2CreateRequest.java

        }
    
        /**
         * {@inheritDoc}
         *
         * @see jcifs.internal.CommonServerMessageBlockRequest#size()
         */
        @Override
        public int size() {
            int size = Smb2Constants.SMB2_HEADER_LENGTH + 56;
            int nameLen = 2 * this.name.length();
            if (nameLen == 0) {
                nameLen++;
            }
    
            size += size8(nameLen);
            if (this.createContexts != null) {
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Sat Aug 23 02:21:31 GMT 2025
    - 22.9K bytes
    - Click Count (0)
  10. src/test/java/jcifs/internal/smb2/ServerMessageBlock2Test.java

                byte[] buffer = new byte[256];
                testMessage.setBytesWritten(0);
                int len = testMessage.encode(buffer, 0);
                assertTrue(len >= Smb2Constants.SMB2_HEADER_LENGTH);
            }
    
            @Test
            @DisplayName("Should handle large MID values")
            void testLargeMidValue() {
                long largeMid = Long.MAX_VALUE;
                testMessage.setMid(largeMid);
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Thu Aug 14 05:31:44 GMT 2025
    - 39.5K bytes
    - Click Count (0)
Back to Top