How to reset credentials of shared network in windows 11?

ComptonAlvaro 166 Reputation points

I have a server with windows 11 and I have a client computer with windows 11 too.

Until now, to connect to a shared folder in the server, in the file explorer of the client I write: \x.x.x.x\MyShared folder. Then I was promted for the credentials. I use a user and password in the server and I never saved the credentials, because I want to be prompted always.

But sice few weeks ago, I am not prompted and I I get an error that says I don't have permissions. I would like to know how I could delete the credentials for that.

I check the manager credentials of the user in panel control, but I don't have any credentials related. Anyway, I delete all the windows credentials that I had. Anyway I knew that it wouldn't solve the problem because this problem happens with another users in the same client computer.

In the server, if I check the events of SMB Server, I can see that I get the error 1006. And in tihs error I can see that the a client tried to connect. The client is the IP of my client computer, but the user that is received is not correct, because the user that SMB Server receives is [NameServer][UserLoggedInClientComputer]. It is a mix of server name and user of the client computer, so how it doesn't exist in the server, it is the reason why I don't have permission.

So for some reason the client send a wrong user, but I am not prompted, so I can't send use the correct credentials. I would like to know if there is some way to reset the shared network credentials to be prmpted again.

In the client I have tried to use the following command:

NET USE * \server_name\share_name

It is said the user is not correct and prompt me for the credentials, I give the credentials of the user in the server, but I get the same error. In the server, I check the event of SMBServer and I see that still the user that is received by the user is the user of the client computer, not the user that I used when I was prompted by the credentials.

I have tried to add a new credential in the user account of my client computer: x.x.x.x\UserInServer and it works. If I delete the credential then I am not prompted and I don't have premissions to connect.

So it seems that if I have set the credentials it uses, if not, it usea wrong credentials and it doesn't work.

Also I would like to be prompted to can decide with which user I want to connect.


Windows 10 Network
Windows 10 Network
Windows 10: A Microsoft operating system that runs on personal computers and tablets.Network: A group of devices that communicate either wirelessly or via a physical connection.
2,292 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
8,630 questions
0 comments No comments
{count} votes

4 answers

Sort by: Most helpful
  1. @CmdrKeene 106 Reputation points

    I believe this can be achieved by activating the policy setting "Network access: Do not allow storage of passwords and credentials for network authentication". Open policy editor (gpedit.msc in your Run box) and navigate to "Computer Configuration\Windows Settings\Security Settings\Local Policies\Security Options" and then enable the option.


  2. MotoX80 32,526 Reputation points

    Map the drive with a .bat file that prompts you for the password.

    @echo off
    echo Enter the password for xxxxxx.
    set /p pswd=""
    net use x: /delete 
    net use x: \\test10\logs %pswd% /user:testuser 
    net use 

    Did you ever try using a different user on the client to see if the problem was with the user or with the computer?

  3. MotoX80 32,526 Reputation points

    As @@CmdrKeene pointed you to, run gpedit and select the All Settings and click on the State column to sort by settings that are configured. Compare both the Computer Configuration and User Configuration with a computer that works. See if you can find a related setting that's different.


    Powershell has a Get-SmbClientConfiguration cmdlet. Compare the output from the problem machine versus one that works.

    This is my Win11 laptop.

    PS C:\> Get-SmbClientConfiguration  
    SkipCertificateCheck                  : False  
    ConnectionCountPerRssNetworkInterface : 4  
    DirectoryCacheEntriesMax              : 16  
    DirectoryCacheEntrySizeMax            : 65536  
    DirectoryCacheLifetime                : 10  
    DormantFileLimit                      : 1023  
    EnableBandwidthThrottling             : True  
    EnableByteRangeLockingOnReadOnlyFiles : True  
    EnableInsecureGuestLogons             : True  
    EnableLargeMtu                        : True  
    EnableLoadBalanceScaleOut             : True  
    EnableMultiChannel                    : True  
    EnableSecuritySignature               : True  
    ExtendedSessionTimeout                : 1000  
    FileInfoCacheEntriesMax               : 64  
    FileInfoCacheLifetime                 : 10  
    FileNotFoundCacheEntriesMax           : 128  
    FileNotFoundCacheLifetime             : 5  
    ForceSMBEncryptionOverQuic            : False  
    KeepConn                              : 600  
    MaxCmds                               : 50  
    MaximumConnectionCountPerServer       : 32  
    OplocksDisabled                       : False  
    RequireSecuritySignature              : False  
    SessionTimeout                        : 60  
    UseOpportunisticLocking               : True  
    WindowSizeThreshold                   : 8  

  4. dw33 1 Reputation point

    Run Credential Manager it should be easy to remove in there

    0 comments No comments