Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 24 for isAnonymous (0.06 sec)

  1. src/test/java/jcifs/smb/SmbResourceLocatorImplTest.java

        }
    
        @Test
        @DisplayName("shouldForceSigning depends on config, creds, and IPC")
        void testShouldForceSigning() {
            when(config.isIpcSigningEnforced()).thenReturn(true);
            when(creds.isAnonymous()).thenReturn(false);
    
            // Case 1: share is IPC$ -> IPC
            SmbResourceLocatorImpl ipc = locator("smb://server/IPC$/");
            assertTrue(ipc.shouldForceSigning());
    
            // Case 2: config disabled
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 17.6K bytes
    - Viewed (0)
  2. src/main/java/jcifs/Credentials.java

         */
        String getUserDomain();
    
        /**
         * Check if these are anonymous credentials.
         * @return whether these are anonymous credentials
         */
        boolean isAnonymous();
    
        /**
         * Check if these are guest credentials.
         * @return whether these are guest credentials
         */
        boolean isGuest();
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 1.6K bytes
    - Viewed (0)
  3. src/main/java/jcifs/context/AbstractCIFSContext.java

         *
         * @see jcifs.CIFSContext#hasDefaultCredentials()
         */
        @Override
        public boolean hasDefaultCredentials() {
            return this.getDefaultCredentials() != null && !this.getDefaultCredentials().isAnonymous();
        }
    
        /**
         * Gets the default credentials for this context.
         *
         * @return the default credentials for this context
         */
        protected abstract Credentials getDefaultCredentials();
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 4K bytes
    - Viewed (0)
  4. src/main/java/jcifs/smb/NtlmContext.java

            this.ntlmsspFlags = this.ntlmsspFlags | NtlmFlags.NTLMSSP_REQUEST_TARGET | NtlmFlags.NTLMSSP_NEGOTIATE_EXTENDED_SESSIONSECURITY
                    | NtlmFlags.NTLMSSP_NEGOTIATE_128;
            if (!auth.isAnonymous()) {
                this.ntlmsspFlags |=
                        NtlmFlags.NTLMSSP_NEGOTIATE_SIGN | NtlmFlags.NTLMSSP_NEGOTIATE_ALWAYS_SIGN | NtlmFlags.NTLMSSP_NEGOTIATE_KEY_EXCH;
            } else if (auth.isGuest()) {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 17.3K bytes
    - Viewed (0)
  5. src/test/java/jcifs/internal/smb1/com/SmbComSessionSetupAndXTest.java

        }
    
        @Test
        void anonymousGuestCredentials() throws Exception {
            setupNegotiateStubs();
    
            NtlmPasswordAuthenticator auth = mock(NtlmPasswordAuthenticator.class);
            when(auth.isAnonymous()).thenReturn(true);
            when(auth.isGuest()).thenReturn(true);
            when(auth.getUsername()).thenReturn("guest");
            when(auth.getUserDomain()).thenReturn("dom");
    
            // Construct
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 6.4K bytes
    - Viewed (0)
  6. src/test/java/jcifs/smb/SmbRenewableCredentialsTest.java

                // no-op for tests
            }
    
            @Override
            public boolean isGuest() {
                return false; // not guest for test purposes
            }
    
            @Override
            public boolean isAnonymous() {
                return false; // not anonymous for test purposes
            }
    
            @Override
            public String getUserDomain() {
                return "TESTDOMAIN"; // test domain for test purposes
            }
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 7K bytes
    - Viewed (0)
  7. src/main/java/jcifs/smb/SmbTreeImpl.java

            }
    
            if (transport.getContext().getConfig().isIpcSigningEnforced() && ("IPC$".equals(this.getShare()) || "IPC".equals(rsvc))
                    && !sess.getCredentials().isAnonymous() && sess.getDigest() == null) {
                throw new SmbException("IPC signing is enforced, but no signing is available");
            }
    
            this.service = rsvc;
            this.inDfs = response.isShareDfs();
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sun Aug 31 08:00:57 UTC 2025
    - 30K bytes
    - Viewed (0)
  8. src/main/java/jcifs/smb/SmbTransportPoolImpl.java

            try (SmbTransportInternal trans = tf.getTransportPool()
                    .getSmbTransport(tf, dc, port, false, !tf.getCredentials().isAnonymous() && tf.getConfig().isIpcSigningEnforced())
                    .unwrap(SmbTransportInternal.class)) {
                trans.ensureConnected();
                return trans.getServerEncryptionKey();
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sun Aug 31 08:00:57 UTC 2025
    - 33.4K bytes
    - Viewed (0)
  9. src/main/java/jcifs/smb/SmbTreeConnection.java

                final SmbTreeImpl t, final DfsReferralData referral, final SmbAuthException sae) throws SmbAuthException, CIFSException {
            try (SmbSessionImpl treesess = t.getSession()) {
                if (treesess.getCredentials().isAnonymous() || treesess.getCredentials().isGuest()) {
                    // refresh anonymous session or fallback to anonymous from guest login
                    try (SmbSessionInternal s =
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 30.4K bytes
    - Viewed (0)
  10. src/main/java/jcifs/http/NtlmHttpURLConnection.java

                    final NtlmPasswordAuthentication npa = (NtlmPasswordAuthentication) this.transportContext.getCredentials();
                    String domain = npa.getUserDomain();
                    String user = !npa.isAnonymous() ? npa.getUsername() : null;
                    String password = npa.getPassword();
                    String userInfo = this.url.getUserInfo();
                    if (userInfo != null) {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 25.6K bytes
    - Viewed (0)
Back to top