Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 31 for writeTime (0.49 sec)

  1. src/test/java/jcifs/internal/smb2/create/Smb2CloseResponseTest.java

                long lastWriteTimeMs = creationTimeMs + 200;
    
                // Write as Windows FileTime format
                SMBUtil.writeTime(creationTimeMs, buffer, 8);
                SMBUtil.writeTime(lastAccessTimeMs, buffer, 16);
                SMBUtil.writeTime(lastWriteTimeMs, buffer, 24);
                SMBUtil.writeTime(creationTimeMs + 300, buffer, 32);
                SMBUtil.writeInt8(4096, buffer, 40);
                SMBUtil.writeInt8(2048, buffer, 48);
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 26.9K bytes
    - Viewed (0)
  2. src/test/java/jcifs/internal/smb2/nego/Smb2NegotiateResponseInputValidationTest.java

            SMBUtil.writeInt4(1024 * 1024, buffer, 36); // maxWriteSize
    
            // System time and server start time
            SMBUtil.writeTime(System.currentTimeMillis(), buffer, 40);
            SMBUtil.writeTime(System.currentTimeMillis(), buffer, 48);
    
            // Security buffer offset and length (no security buffer)
            SMBUtil.writeInt2(0, buffer, 56); // offset
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Sun Aug 31 08:00:57 UTC 2025
    - 15.8K bytes
    - Viewed (0)
  3. docs/smb3-features/05-rdma-smb-direct-design.md

        Arrays.fill(data, (byte)0x42);
        
        long start = System.currentTimeMillis();
        
        try (OutputStream os = file.getOutputStream()) {
            os.write(data);
        }
        
        long writeTime = System.currentTimeMillis() - start;
        
        // Read back
        start = System.currentTimeMillis();
        byte[] readData = new byte[data.length];
        
        try (InputStream is = file.getInputStream()) {
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Sat Aug 16 02:53:50 UTC 2025
    - 35.9K bytes
    - Viewed (0)
  4. src/test/java/jcifs/internal/smb1/com/SmbComNegotiateResponseTest.java

            buffer[bufferIndex++] = 0;
            buffer[bufferIndex++] = 0;
            buffer[bufferIndex++] = 0;
            // serverTime
            long time = new Date().getTime();
            SMBUtil.writeTime(time, buffer, bufferIndex);
            bufferIndex += 8;
            // serverTimeZone
            buffer[bufferIndex++] = (byte) 0x80;
            buffer[bufferIndex++] = (byte) 0xFF;
            // encryptionKeyLength
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.4K bytes
    - Viewed (0)
  5. src/test/java/jcifs/internal/fscc/FileBasicInfoTest.java

            // Decode
            FileBasicInfo decoded = new FileBasicInfo();
            decoded.decode(buffer, 0, 36); // decode reads 36 bytes
    
            // Note: When encoding time 0, SMBUtil.writeTime writes 0 directly,
            // but SMBUtil.readTime interprets 0 as Jan 1, 1601 in Unix time (-11644473600000)
            // This is the expected behavior for Windows FILETIME
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.5K bytes
    - Viewed (0)
  6. src/main/java/jcifs/smb1/smb1/ServerMessageBlock.java

            final int hi = readInt4(src, srcIndex + 4);
            final long t = (long) hi << 32L | low & 0xFFFFFFFFL;
            return t / 10000L - MILLISECONDS_BETWEEN_1970_AND_1601;
        }
    
        static void writeTime(long t, final byte[] dst, final int dstIndex) {
            if (t != 0L) {
                t = (t + MILLISECONDS_BETWEEN_1970_AND_1601) * 10000L;
            }
            writeInt8(t, dst, dstIndex);
        }
    
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Thu Aug 14 07:14:38 UTC 2025
    - 19.7K bytes
    - Viewed (0)
  7. src/test/java/jcifs/internal/smb1/SMB1SigningDigestTest.java

            assertTrue(result.contains("0102030405060708090A0B0C0D0E0F10"));
        }
    
        @Test
        @DisplayName("Test writeUTime with zero time")
        void testWriteUTimeWithZeroTime() {
            byte[] dst = new byte[4];
    
            SMB1SigningDigest.writeUTime(mockConfig, 0L, dst, 0);
    
            assertEquals((byte) 0xFF, dst[0]);
            assertEquals((byte) 0xFF, dst[1]);
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 18.1K bytes
    - Viewed (0)
  8. src/main/java/jcifs/smb1/smb1/SmbRandomAccessFile.java

            // ensure file is open
            if (!file.isOpen()) {
                file.open(openFlags, 0, SmbFile.ATTR_NORMAL, options);
            }
    
            int w;
            do {
                w = len > writeSize ? writeSize : len;
                file.send(new SmbComWriteAndX(file.fid, fp, len - w, b, off, w, null), write_andx_resp);
                fp += write_andx_resp.count;
                len -= write_andx_resp.count;
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 14.1K bytes
    - Viewed (0)
  9. src/test/java/jcifs/smb1/smb1/SmbComCloseTest.java

        }
    
        /**
         * Verify that writeParameterWordsWireFormat writes the file id and the
         * unsigned time correctly.  The last write time is zero which should be
         * encoded as four 0xFF bytes by {@code writeUTime}.
         */
        @ParameterizedTest(name = "fid={0}, lastWriteTime={1}")
        @MethodSource("validParams")
        @DisplayName("happy: writeParameterWordsWireFormat writes correct bytes")
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 4.8K bytes
    - Viewed (0)
  10. src/test/java/jcifs/internal/smb1/com/SmbComQueryInformationResponseTest.java

            long lastWriteTime = System.currentTimeMillis();
            int fileSize = 12345678;
    
            SMBUtil.writeInt2(fileAttributes, buffer, bufferIndex);
            SMBUtil.writeUTime(lastWriteTime, buffer, bufferIndex + 2);
            SMBUtil.writeInt4(fileSize, buffer, bufferIndex + 6);
    
            // Read the data
            int bytesRead = response.readParameterWordsWireFormat(buffer, bufferIndex);
    
    Registered: Sat Dec 20 13:44:44 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.9K bytes
    - Viewed (0)
Back to top