Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 5 of 5 for encodedSize (0.26 sec)

  1. src/test/java/jcifs/internal/smb2/nego/NegotiateContextResponseTest.java

                byte[] buffer = new byte[originalContext.size()];
                int encodedSize = originalContext.encode(buffer, 0);
    
                PreauthIntegrityNegotiateContext decodedContext = new PreauthIntegrityNegotiateContext();
                int decodedSize = decodedContext.decode(buffer, 0, encodedSize);
    
                // Assert
                assertEquals(encodedSize, decodedSize);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 07:14:38 UTC 2025
    - 19.4K bytes
    - Viewed (0)
  2. src/test/java/jcifs/internal/smb2/create/CreateContextRequestTest.java

            private byte[] data;
            private int encodedSize;
            private boolean throwOnEncode = false;
            private boolean throwOnSize = false;
            private int sizeCallCount = 0;
            private int encodeCallCount = 0;
    
            public TestCreateContextRequest(byte[] name) {
                this.name = name;
                this.encodedSize = name != null ? name.length + 16 : 16; // 16 bytes for header
            }
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 24.9K bytes
    - Viewed (0)
  3. src/test/java/jcifs/internal/smb2/nego/NegotiateContextRequestTest.java

                context = new PreauthIntegrityNegotiateContext(mockConfig, hashAlgos, salt);
                int encodedSize = context.encode(buffer, 0);
    
                PreauthIntegrityNegotiateContext decoded = new PreauthIntegrityNegotiateContext();
                int decodedSize = decoded.decode(buffer, 0, encodedSize);
    
                assertEquals(encodedSize, decodedSize);
                assertArrayEquals(hashAlgos, decoded.getHashAlgos());
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 18.8K bytes
    - Viewed (0)
  4. src/test/java/jcifs/smb/compression/CompressionNegotiateContextTest.java

        @Test
        @DisplayName("Test context encoding")
        public void testEncoding() {
            byte[] buffer = new byte[256];
            int encodedSize = context.encode(buffer, 0);
    
            assertTrue(encodedSize > 8); // Minimum size: count + padding + flags + algorithms
            assertEquals(context.size(), encodedSize);
        }
    
        @Test
        @DisplayName("Test context decoding")
        public void testDecoding() throws SMBProtocolDecodingException {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sun Aug 31 08:00:57 UTC 2025
    - 5.6K bytes
    - Viewed (0)
  5. src/test/java/jcifs/internal/smb1/trans2/Trans2SetFileInformationTest.java

        @ParameterizedTest
        @ValueSource(ints = { 0, 1, 10, 100, 1000 })
        void testFileInformationEncodeDifferentSizes(int encodeSize) {
            when(mockFileInfo.encode(any(byte[].class), anyInt())).thenReturn(encodeSize);
    
            trans2SetFileInfo = new Trans2SetFileInformation(config, TEST_FID, mockFileInfo);
    
            byte[] buffer = new byte[2048];
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 17.8K bytes
    - Viewed (0)
Back to top