Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.

Windows 7: Deleting Temp Credentials

24 Aug 2012   #1

Windows 7 Ultimate x64
Deleting Temp Credentials

Here's my setup:
At my church I have multiple computers (all Win7 Ultimate) networked to a server (2008 R2), some of which are personal ones with specific passwords and others that are shared ones with just one generic user and the same generic password so (non-technical) members can easily access needed files. Each user or PC has specific permissions assigned to it.

I also have a personal (password-protected) server (2008 R2) on the network where I store my own files synced with various PC's, phones, and tablets so I can get at any file on any device from anywhere I happen to be (like a personal cloud ).

On occasion I have need to get to one of my own files from a shared PC and I can get to them easily by inputting my "cloud" username and password and not checking the box to remember me (so it is not added to the credential manager).

So here's the issue:
If I close out the personal server files window after doing what I need on a shared PC, anyone else who uses the PC after me can access it unless I log off and back on with the generic info (which I'd rather not have to do).

Is there a simpler way to delete my temporary credentials when I close out the window? They are not included in the credential manger because they are not set to be remembered, but appear to be held in one of the temp folders or something until I log off.

My System SpecsSystem Spec
26 Aug 2012   #2

W7 Pro SP1 64bit

Welcome to the Seven Forums!

The short answer is:
net use * /d /y

The slightly longer answer is:
The short answer does not warn you that it deletes all mapped drives :-(

After you are finished access your file(s), close any app that has them open - including any Windows (file) Explorer windows. Open a cmd prompt windows and use the " net use * /d /y " command line to delete all mapped drives [even if you did not map a drive letter to get to your file(s)].

The even longer answer is:
You will find people asking the same question that you did. Some were given the short answer and some replied back that it did not work for them. The reason for this apparent (and sometimes real) failure is a bit complex. After the "net use delete" command line is issued, a certain period of inactivity must occur before the password will be forgotten. People tend to be impatient, they tend to reopen the Windows (file) Explorer to check if the password has been forgotten - doing that resets the inactivity timer.

And then there are apps like iTunes that might keep the connection alive while it indexes stuff on your share - hence a total "failure" to delete the cached password.

I made a video that shows this timeout and I intentionally reopen the Windows (file) Explorer to show that you can still connect to the share for a while after the "net use delete" command line has been issued:

If you connect to your files a lot - consider putting a batch file on each computer:

net use * \\W7PRO32BIT\users /user:username * /persistent:no
explorer \\W7PRO32BIT\users
net use * /d /y
You can access your files during the first pause.

Edit: you could of course replace the "*" in "net use * /d /y" with the actual drive letter that you mapped and the other drive letters should remain intact, I just cannot test that right now. Also, the video shows a connection to the server/share using with this info "W7pro32bit:microsoft-ds" on the netstat return info. sometimes the computer name will be an IPv6 address instead.

Edit2: To quote Microsoft: "Multiple connections to a server or shared resource by the same user, using more than one user name, are not allowed. Disconnect all previous connections to the server or shared resource and try again." So, if your users have drive letters already mapped to the same server that you are wanting to connect to, then have the batch file disconnect everything, connect you, pause, disconnect you and then reconnect them. There; wasn't that easy
My System SpecsSystem Spec
27 Aug 2012   #3

Windows 7 Ultimate x64

Thanks for the multiple ideas.
So far it seams the easiest thing to do is log off the PC and back on if I happen to use it to access my personal server.
My System SpecsSystem Spec


 Deleting Temp Credentials

Thread Tools

Similar help and support threads
Thread Forum
Having Network Trouble after deleting temp files
I recently wanted to play a game, but it wasnt working, contacted support, blah blah blah, but the support guy said one of the ways i might improve it was by deleting my Temp files, so I did that, but I forgot to empty my recycle bin, and I restarted my computer. I opened it up, and the theme had...
Network & Sharing
Q: Deleting temp files?
What is the best way to clear up the files in the folder? C:\Users\<<username>>\AppData\Local\Temp Disk Cleanup does not scan this folder, so does not select it for deletion. One app that I installed left behind its installer file (almost 2 GB) in this folder. And I don't really want to back...
Performance & Maintenance
Temp folders deleting
Hi guys, I need your help. First let me say I have Googled the heck out of this dilemma with no results. I have run both Malware Bytes, Super spyware and even Windows Security Essentials (this took 2 hours)it found two baddies which were deleted. The other malware detectives found a bunch of...
General Discussion
deleting temp's
is it ok to just delet everything in the folder? C:\Users\maxheadroom\AppData\Local\Temp thanks
Performance & Maintenance
Deleting C: Windows --> Temp Files
I have a question. Can i safely delete files from this folder C: Windows Temp as it is 9,9GB in size. Picture 1 I know that you can delete files from folder when you open Start and then type %temp% but can you delete files in that folder as first picture shows? Would appreciate the help.
Performance & Maintenance

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 23:04.
Twitter Facebook Google+