Skip to contentSkip to conversation

Secure network fileserving Linux <-> Linux

OFFTOPIC Joseph Mathewson 9 participants 10 messages Sep 5, 2001 – Sep 6, 2001

lore
Share & tools
lore
#0 lore raw

Sorry to ask another annoying question so quickly after my SCSI problems, but

Does anyone know of/use a secure network filesharing system on a Linux network? We currently have a room of about 10 machines, mostly Linux clients (some MacOS X, soon to come Sun and HP-UX boxes) and servers (all running Linux).

For some time now, we've been using NFS for filesharing /home and have been extremely concerned about security. All the clients in theory run the same uids/gids, thanks to LDAP, but that doesn't stop someone plugging in an unauthorized machine and merrily destroying everyone's home directories.

Apparently some work was done to Kerberize various bits of NFS, and Sun have a secure(r) implementation in Solaris.

Does anyone know of a free (preferably easy :) way of secure Linux <-> Linux filesharing? Apologies if that seems like a flame, maybe I've missed the obvious solution. (Preferably a solution that doesn't involve editing /etc/exports to only allow connections from specified IPs, because if someone was going to go to the length of destroying our data, they could fake that. Similarly, MAC addresses.)

Joe.

+-------------------------------------------------+
| Joseph Mathewson <[email protected]>          |
+-------------------------------------------------+
#1 lore raw

One possible solution might be samba, but I'd be lying if I asserted anything about its security, I do know that it can be configured to operate entirely over SSL though.

Fred

__________________________________________________

Quoted 35 lines · Joseph Mathewson

Sorry to ask another annoying question so quickly after my SCSI problems, but

Does anyone know of/use a secure network filesharing system on a Linux network? We currently have a room of about 10 machines, mostly Linux clients (some MacOS X, soon to come Sun and HP-UX boxes) and servers (all running Linux).

For some time now, we've been using NFS for filesharing /home and have been extremely concerned about security. All the clients in theory run the same uids/gids, thanks to LDAP, but that doesn't stop someone plugging in an unauthorized machine and merrily destroying everyone's home directories.

Apparently some work was done to Kerberize various bits of NFS, and Sun have a secure(r) implementation in Solaris.

Does anyone know of a free (preferably easy :) way of secure Linux <-> Linux filesharing? Apologies if that seems like a flame, maybe I've missed the obvious solution. (Preferably a solution that doesn't involve editing /etc/exports to only allow connections from specified IPs, because if someone was going to go to the length of destroying our data, they could fake that. Similarly, MAC addresses.)

Joe.

+-------------------------------------------------+

| Joseph Mathewson <[email protected]> |

+-------------------------------------------------+
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

#2 lore raw
In reply to Joseph Mathewson
Quoted 17 lines · Joseph Mathewson

Sorry to ask another annoying question so quickly after my SCSI problems, but

Does anyone know of/use a secure network filesharing system on a Linux network? We currently have a room of about 10 machines, mostly Linux clients (some MacOS X, soon to come Sun and HP-UX boxes) and servers (all running Linux).

For some time now, we've been using NFS for filesharing /home and have been extremely concerned about security. All the clients in theory run the same uids/gids, thanks to LDAP, but that doesn't stop someone plugging in an unauthorized machine and merrily destroying everyone's home directories.

Apparently some work was done to Kerberize various bits of NFS, and Sun have a secure(r) implementation in Solaris.

Quoted 6 lines

Does anyone know of a free (preferably easy :) way of secure Linux <-> Linux filesharing? Apologies if that seems like a flame, maybe I've missed the obvious solution. (Preferably a solution that doesn't involve editing /etc/exports to only allow connections from specified IPs, because if someone was going to go to the length of destroying our data, they could fake that. Similarly, MAC addresses.)

Hello...

What about switching to IPSec ?

Should work between Linuxboxes....or why shouldn't it ?

Solong...
Frank.

--
Frank Schneider, <[email protected]>.
Microsoft isn't the answer.
Microsoft is the question, and the answer is NO.
... -.-

#3 lore raw
In reply to Joseph Mathewson

Joseph Mathewson <[email protected]>:

Quoted 17 lines

Sorry to ask another annoying question so quickly after my SCSI problems, but

Does anyone know of/use a secure network filesharing system on a Linux network? We currently have a room of about 10 machines, mostly Linux clients (some MacOS X, soon to come Sun and HP-UX boxes) and servers (all running Linux).

For some time now, we've been using NFS for filesharing /home and have been extremely concerned about security. All the clients in theory run the same uids/gids, thanks to LDAP, but that doesn't stop someone plugging in an unauthorized machine and merrily destroying everyone's home directories.

Apparently some work was done to Kerberize various bits of NFS, and Sun have a secure(r) implementation in Solaris.

Quoted 6 lines

Does anyone know of a free (preferably easy :) way of secure Linux <-> Linux filesharing? Apologies if that seems like a flame, maybe I've missed the obvious solution. (Preferably a solution that doesn't involve editing /etc/exports to only allow connections from specified IPs, because if someone was going to go to the length of destroying our data, they could fake that. Similarly, MAC addresses.)

Free if someone already owns a .357 Magnum.... (well, cost of ammo:)....

First answer:

Not possible.
1. You pose an unsecured network (anyone can plug in a host)
2. Physical access to the hosts (anyone could reconfigure a host)
3. No physical security (anyone can get in the room, with unauthorized equipment).

Kerberos won't help either - The only parts of NFS that were kerberized was the initial mount. Everything else uses filehandles/UDP. Encryption doesn't help either - slows the entire network down too much.

Second answer:

1. Get physical security over the network. Prevent unauthorized personnel from adding unauthorized equipment.
2. Now prevent external logical monitoring of the network with a switched environment (prevents one host from seeing traffic targeted at a different host).
3. Use kerberos for general user logins.
4. Do not let users have direct physical access to the hosts.

Usually, you don't have enough money invested in a user lab (which is what it sounds like) to make it worth the effort to apply.

Third answer:

A more reasonable way is to configure the user accessable systems as just X terminals (no MACs though) on a switched ethernet. Configure
the switch with a fixed MAC address for each target (prevents hardware
substitution). Now you can put the actual user work machines as compute servers in a different room. The compute servers (the ones users log into) can then use a physically isolated network (users can't plug things into it) for NFS to a file server.

This is still more extensive (and expensive) than a small lab is usually willing to accept.

Fourth answer:

The minimum would be to use a switched ethernet, with fixed MAC addressing. This prevents walk-in users from substituting equipement, and it limits the ability to sniff the network. Only packets destined for one IP would be visible, and the switch should be able to signal an alarm if it detects an unauthorized MAC address (as well as refuse to work). This still allows for NFS, and a higher throughput as well (each node can use the full bandwidth).

The fourth answer is more likely to be acceptable to management and the users (the carrot is the higher performance). It doesn't help the reconfiguration possiblity (booting a floppy with a different OS on a host already authorized to use the network).

-------------------------------------------------------------------------
Jesse I Pollard, II
Email: [email protected]

Any opinions expressed are solely my own.

#4 lore raw
Quoted 15 lines · Jesse Pollard

Third answer:

A more reasonable way is to configure the user accessable systems as just X terminals (no MACs though) on a switched ethernet. Configure
the switch with a fixed MAC address for each target (prevents hardware
substitution). Now you can put the actual user work machines as compute servers in a different room. The compute servers (the ones users log into) can then use a physically isolated network (users can't plug things into it) for NFS to a file server.

This is still more extensive (and expensive) than a small lab is usually willing to accept.

Fourth answer:

Quoted 7 lines

The minimum would be to use a switched ethernet, with fixed MAC addressing. This prevents walk-in users from substituting equipement, and it limits the ability to sniff the network. Only packets destined for one IP would be visible, and the switch should be able to signal an alarm if it detects an unauthorized MAC address (as well as refuse to work). This still allows for NFS, and a higher throughput as well (each node can use the full bandwidth).

Both your Third and Fouth answer depend on MAC addresses locked down on the switch. This is fatally flawed since (as the orginal poster pointed out), changing your MAC address to match the expected MAC is quite easy.

# ifconfig eth0 ether A0:B1:C2:D3:E4:F4

How can you get the expected MAC address?

1. Walk up to an allowed computer, unplug computer from wall jack. Plug cross over cable from allowed computer into laptop. Sniff MAC address from frames generated by allowed computer.

- Reconfigure your eth0 with allowed MAC, plug into network

2. Walk up to an allowed computer, unplug computer from wall jack. Plug into wall jack and sniff destination MAC address on frames sent by switch.

- Reconfigure your eth0 with allowed MAC

One solution is to require layer 2 authentication from the switch, before it fowards frames on that port. Before DHCP. This process could be repeated every time link is lost. The switch uses RADIUS off of some authentication server.

The 802.11x standard(s) implement this for wireless networks, it can also be used on wired networks (the specs allow it at least).

Dax

#5 lore raw
In reply to Jesse Pollard
Quoted 5 lines · Jesse Pollard

Not possible.
1. You pose an unsecured network (anyone can plug in a host)
2. Physical access to the hosts (anyone could reconfigure a host)
3. No physical security (anyone can get in the room, with unauthorized equipment).

Did you consider AFS?

Might be overkill for his environment, but it does do ACLs.

--
-- John E. Jasen ([email protected])
-- In theory, theory and practise are the same. In practise, they aren't.

#6 lore raw
Quoted 3 lines · In article <[email protected]>…

Did you consider AFS?

Might be overkill for his environment, but it does do ACLs.

Does it do data encryption? I think you may need to run IPSec, which does not fit too well into the required environemnt.

Greetings
Bernd

#7 lore raw

Bernd Eckenfels <[email protected]>:

Quoted 7 lines
Quoted 3 lines · In article <[email protected]>…

Did you consider AFS?

Might be overkill for his environment, but it does do ACLs.

Does it do data encryption? I think you may need to run IPSec, which does not fit too well into the required environemnt.

I thought of AFS, but was not sure clients existed for all systems that would likely be in a lab. I should have listed it as a possiblility though.

-------------------------------------------------------------------------
Jesse I Pollard, II
Email: [email protected]

Any opinions expressed are solely my own.

#8 lore raw
In reply to Jesse Pollard
Quoted 1 line · John Jasen

Did you consider AFS?

There is also Coda, which I have had good luck with. It also supports volume replication, ACLs, and disconnectecd operation, to boot.

Signature · 6 lines
When you look into the abyss,the abyss also looks into you.
	- Friedrich Nietzche
**
Penguin Sympathizer
Bryon Roche, Kain <[email protected]>
<[email protected]>
#9 lore raw
In reply to Joseph Mathewson
Quoted 4 lines · Jesse Pollard

Kerberos won't help either - The only parts of NFS that were kerberized was the initial mount. Everything else uses filehandles/UDP. Encryption doesn't help either - slows the entire network down too much.

I disagree! First of all you can always use NFS over TCP, so much for "every thing else uses filehandles/UDP". (No that this improves security, but it can improve reliability!)

True: krb5 only authenticates the mount, but krb5i also computes a MD5-based message authentication code on every RPC request to the server and every RPC reply to the client, thus providing integrity protection. krb5p uses DES encryption to provide privacy. Unfortunately only Solaris with SEAM and SEAS (or AdminPack for Solaris 8) seems to implement this. I would love to see a Linux implementation of this!

I would like to recommend "Managing NFS and NIS" (2nd ed) from O'Reilly, especially chapter 12 "Network Security". That chapter discusses the mechanismns described above as well as performance and relation to IPsec (for the impatient: using AH+ESP will give you HOST-based security, while using krb5+krb5i+krb5p will give you USER-based security)

As for encryption slowing down the network: security does not come for free. It is the task of the System Administrator to evalute his security requirements against the required performance of the installation and take the appropriate measures. Nobody ever said that was easy. It if was every MCSE could do it!

The author of "Managing NFS and NIS" (2nd ed) gave some figures on performance degradation using krb5 (using two Ultra 5 w Solaris 8, using NFS over TCP):

	Auth	Throughput	Degradation	CPU util.
                 (MB/sec)	rel. to "sys"

	sys	5.4		-		69%
	krb5	5.26		2.6%		70%
	krb5i	4.44		17.7%		77%
	krb5p	1.45		73.1%		99%

(Test involved writing a 200MB file to the tmpfs of the server using the mkfile utility. I am sure one could run better tests, but...)

Now i would be more concerned with the increas in CPU utilisation than the throughput degradation. Why? If i truly need to protect sensitive information with encryption, i can wait for the data. But making the server unusable for the duration of the data transfer is in most cases not acceptable.

Dominik Kubla

Signature · 4 lines
ScioByte GmbH, Zum Schiersteiner Grund 2, 55127 Mainz (Germany)
Phone: +49 6131 550 117  Fax: +49 6131 610 99 16

GnuPG: 717F16BB / A384 F5F1 F566 5716 5485  27EF 3B00 C007 717F 16BB