Securely share drive on home network

gx240

Distinguished
Jan 10, 2010
27
0
18,530
I want to securely share a computer's whole drive (the C drive for example) on a home network. I know how to do this with Windows XP's simple file sharing, but that makes it available to everyone on the network. Is there some way to protect it so only certain people on the network can access it (like with a username and password)?
 
Solution
That may be because you have previously connected to that share as guest. What happens if you disable the guest account?

Edit: Alternatively, try using the net user command with the /user switch:

net use t: \\computername\sharename /user:fred

gx240

Distinguished
Jan 10, 2010
27
0
18,530
As I said, I know how to enable simple file sharing. That doesn't let you control who has access to a file. If you share a file it's available to everyone on the network.
 
Oh, another thing you can do, although it involves some cost. Get a NAS, those usually come with their own operating system and you can set user permissions through there.

Also, who else would be on your home network? As long as you take the proper steps and secure your router well, share away. Someone would have to physically enter your rooms and connect a PC to the router to get to your shares.

Sure there are hackers that can break inside your firewall anyway, but in that case, having some XP file rights won't do much good as that is about as easy to break as hacking past a firewall.
 

gx240

Distinguished
Jan 10, 2010
27
0
18,530
I'm using XP Professional, not Home. I can see the security tab, and I can set permissions for different groups and users. However, If I try to connect to this computer with any other Windows box it seems to automatically use the guest account. Is there some way to login with a different username and password?
 
On the "Sharing" tab there is a "Permissions" button. This allows you to specify which users can connect to the share. (Although setting file security should work too - even if a guest can connect they won't be able to access a file to which they haven't been give permission.)
 

gx240

Distinguished
Jan 10, 2010
27
0
18,530
Ok great now how do I connect to that computer as anyone other than guest? If you just use \\computername or \\ipaddress it connects as guest. Is there some way to connect as another user?
 
That may be because you have previously connected to that share as guest. What happens if you disable the guest account?

Edit: Alternatively, try using the net user command with the /user switch:

net use t: \\computername\sharename /user:fred
 
Solution

gx240

Distinguished
Jan 10, 2010
27
0
18,530
Alright your last response seems to have solved it. By using the following command I can mount the whole drive:

"net use t: \\computername\c$ /user:computername\administrator"

The only outstanding issue I have is that I never get a prompt asking for a username and password if I try to connect to another computer. It just automatically connects me as the last use I connected with. For example, even after I disabled the guest account it would connect me as guest if I just used \\computername. Now my last connection was as computername\administrator, so it always connects me as that. I suppose it's not a huge deal, but is there some way to force it to ask for username/pass instead of just using the last one? (I should say I even tried restarting both computers, and it still used the last login.)
 
You could try:

net use * /d

to disconnect all existing connections. Then do

net use /persistent:NO

to stop Windows remembering connections in future.

PS. When I said disable the Guest account I meant on the computer that you are connecting to rather than the one that you are connecting from - sorry if I wasn't clear about this.
 

gx240

Distinguished
Jan 10, 2010
27
0
18,530
I disabled guest accounts on both computers just to make sure. I also disabled all other accounts for the moment, so the only thing running on both computers is administrator.

I just ran the two commands you listed on both computers, and they completed successfully. The "net use" command now returns the same thing on both:

"New connections will not be remembered. There are no entries in the list."

However, when I connect to \\computername, it still connects without a user/pass prompt. Is there somewhere else this information could be stored?
 
In my experience you can connect to just a computer, to browse shares, without authentication but as soon as you try to connect a share you need to present credentials. However, I believe that if there is a user on the remote computer with the same name and password as the one you are logged on to your computer with it will automatically use those credentials.
 

gx240

Distinguished
Jan 10, 2010
27
0
18,530


That was the issue. I hadn't even considered that it would just automatically log in, if it found the same password for the administrator account.

I think that resolves most of the issues. Thank you very much for your time and help.