Subject: netatalk security vs. ftp, ssh

From: Kevin Chan <[email-masked]>
Date: Fri, 28 Jul 2000 14:53:18 -0700

Hi, I am the systems administrator for my company and I have been trying to 
find a way to shut down ftp access to our server.  This would entail 
finding an alternative file transfer protocol, such as some sort of GUI-scp 
or a combination of netatalk and samba(?) or something else.

What I really want to know is if there are any place (or anyone) that will 
tell me the vulnerabilities of using netatalk.  I am convinced that it is 
an improvement over ftp, but I am not convinced that I should implement 
it.  Furthermore, we just moved our server and though I have not compiled 
pam_smb or anything, the chooser menu says that the passwords are encripted 
(whereas before it use to be clear-text).  I think this is due to the new 
kernel, but can anyone enlighten me on this?

Thanks in advance.

KevinChan

---

From: Tom Fitzgerald <[email-masked]>
Date: Fri, 28 Jul 2000 19:42:50 -0400

> tell me the vulnerabilities of using netatalk.

1) File data is not encrypted, so existing sessions are vulnerable to IP
   spoofing attacks.  You can block outside attacks with appropriate source
   address filters at your router, but inside attacks are harder to block.
   Authentication handshakes are encrypted, so an attacker is out of luck
   unless a session has already been set up.

2) Unless the admin has disabled cleartext passwords (which isn't hard),
   clients can send their passwords in the clear.  Double-randnum
   authentication is pretty darn good as authentication methods go.  With
   single-randnum authentication, an inside attacker can impersonate a
   server without the client knowing.

3) To use encrypted authentication with clients older than MacOS 9, the
   user passwords must be stored in cleartext on the server.  This isn't
   actually as much of a problem as one might think, since anyone who can
   break in far enough to get the passwords could also get the passwords
   by other means even if they were encrypted on disk.

4) Users can walk away from their Macs leaving network drives mounted
   and visible on the desktop.  There's no easy way to time out idle
   connections.

5) If the authentication handshake can be sniffed, it's vulnerable to
   a dictionary attack.  This is no different from scp/ssh.

I'd put netatalk at about the same security level as AFS or kerberized
ftp, better than SMB or NFS, not as good as scp (though the server
authentication is better than scp's in some ways).

---

From: andrew morgan <[email-masked]>
Date: Fri, 28 Jul 2000 17:10:51 -0700 (PDT)

> kernel, but can anyone enlighten me on this?

The DATA stream in a netatalk session is not encrypted, but you can have
several forms of encrypted LOGIN (Diffie-Hellman exchange or random number
exchange).  If you have encrypted passwords now, it is probably because
netatalk was compiled with that support or you have the openssl libraries
available now.

	Andy

---

From: Harry Zink/Netatalk List <[email-masked]>
Date: Fri, 28 Jul 2000 20:58:59 -0700

on 7/28/00 2:53 PM, Kevin Chan at [email-masked] wrote:

> I am convinced that it is
> it.

Not entirely sure about that - the ftp process is not as memory hungry as
netatalk, and, as far as I can tell, does provide for better performance.

Of course, if you are dealing with Mac users, netatalk provides for far
better convenience.

Harry
-- 
CAN'T SEE MAC IN CHOOSER UNDER RedHat 6.2: If you get errors starting
AppleTalk under RedHat 6.2 and Mandrake 7.1, you need to manually add "alias
net-pf-5 appletalk" to your /etc/conf.modules file.

---

From: Harry Zink/Netatalk List <[email-masked]>
Date: Fri, 28 Jul 2000 21:00:55 -0700

on 7/28/00 4:42 PM, Tom Fitzgerald at [email-masked] wrote:

> There's no easy way to time out idle
> connections.

Is this a problem with the platform netatalk runs on?  I can set any Apple
Mac ASIP server to time out idle connections after XX minutes.

Harry

---

From: Harry Zink/Netatalk List <[email-masked]>
Date: Fri, 28 Jul 2000 21:01:44 -0700

on 7/28/00 4:42 PM, Tom Fitzgerald at [email-masked] wrote:

> user passwords must be stored in cleartext on the server.

Tom:

Any HOWTO on setting up encrypted passwords well?

Any special way to set up DHX autehntication under OS 9?

Harry

---

From: andrew morgan <[email-masked]>
Date: Fri, 28 Jul 2000 21:19:45 -0700 (PDT)

>    by other means even if they were encrypted on disk.

I have to disagree with this.  I have DHX encrypted logins working with
my mac running OS 8.6.  This is using PAM and a regular /etc/passwd file
on the server.  Maybe this is only true for randnum encryption?

	Andy

---

From: Ron Chmara <[email-masked]>
Date: Sun, 30 Jul 2000 19:35:51 -0700

>    unless a session has already been set up.

My personal fave Mac security hole: There is no stored key, authentication,
_whatever_, to guarantee that a server is the same entity from session to
session....Last time I spoke with apple about this, newer clients could
be tuned to _not_ fall back to cleartext, but most clients will happily
fail to recognize a server randnum or DHX, and fall back to cleartext.

Here's how an inside attack works:
1. Badguy with a laptop sets up netatalk, configures the machine to have
the same server name. Doesn't set up any password login besides cleartext.

2. Badguy laptop jacks into network, SYN's the valid appleshare server into
silence, thus making the mac users select -his- machine in the chooser.

3. Badguy laptop then collects cleartext passwords for 5-10 minutes, (as
the users fail to login, but happily divulge passwords (see cleartext,
above)in the process). If he's lucky, the server admin may even try his
own user/pass combo. >;-)>

4. At first sign of trouble, badguy lets up on SYN flood (thus, "fixing"
the login problem).

With ssh, you are warned durning the key exchange if a server identity
is being spoofed. No suck luck with ftp or asip.

-Bop

--
Brought to you from iBop the iMac, a MacOS, Win95, Win98, LinuxPPC machine,
which is currently in MacOS land.  Your bopping may vary.

---

From: "Radar O'Reilly" <[email-masked]>
Date: Mon, 31 Jul 2000 08:30:07 -0400 (EDT)

> is being spoofed. No suck luck with ftp or asip.

mmm...kerberos.

If you can set up a kerberos domain, you can provide secure and
doubly-authenticated logins, ftp, and (with a little screaming and moaning)
netatalk functionality. Without the need for a stored key.

 __________/| Nathan "Radar" Willard MC '00     | "A Sucking Chest Wound is
(_|__|_____\|________      PO Box 203927        |   nature's way of telling 
     |_|_____________)- New Haven, CT 06520     |     you to slow down."

---

From: Tom Fitzgerald <[email-masked]>
Date: Mon, 31 Jul 2000 14:33:09 -0400

> Any HOWTO on setting up encrypted passwords well?

Sounds to me like the ultimate HOWTO is: "Don't touch any prepackaged
RPM with a 10-foot pole.  Always get the source, compile and install it
yourself."

I dunno, for me it just worked on the first attempt.  afpd.conf is

"Server Name@Zone" -icon -nocleartxt -randnum -setpassword -uamlist 
uams_randnum.so

Create .passwd files in everyone's home directories, mode 0600, owned
by the user and in the user's primary group, containing the password in
cleartext (with or without a trailing newline).

> Any special way to set up DHX autehntication under OS 9?

Haven't done it yet (too much legacy OS 8 stuff).  Anyone else?

---

From: "Daniel E. Lautenschleger" <[email-masked]>
Date: Mon, 31 Jul 2000 14:19:10 -0500 (CDT)

Sounds like your .AppleDouble permissions need to be reviewed.
-Dan

Daniel E. Lautenschleger
University of Wisconsin
R.M. Bock Laboratories
Network Administrator and Computer Support
[email-masked]
608.262.3403

---

From: Tom Fitzgerald <[email-masked]>
Date: Mon, 31 Jul 2000 15:15:52 -0400

> fail to recognize a server randnum or DHX, and fall back to cleartext.

For what it's worth, users with clues will see this immediately since
the "cleartext password" notice shows up next to the username/password
prompt.

It'll also be obvious that valid username/password combinations aren't
working.  It should be clear to everyone that an attack is happening
and it might be time for a global password change.

> silence, thus making the mac users select -his- machine in the chooser.

This doesn't sound right.....  SYN-bombing will keep the appleshare server
from accepting AS/IP connections, but it won't affect what appears in the
chooser since that's coming directly over the appletalk protocol, not IP.

In fact, won't the appletalk routers start screaming when two appletalk
servers start advertising the same server name?

> is being spoofed.

Only if a connection has already been established once.  The first time
you connect, you have to take it on faith that you got the correct server.
(This is pretty much unavoidable unless you have a trusted central server
to authenticate all the other servers.)

---

From: Tom Fitzgerald <[email-masked]>
Date: Mon, 31 Jul 2000 15:29:00 -0400

> on the server.  Maybe this is only true for randnum encryption?

Er, you're right.  Anything from MacOS 8.1 on can do DHX as long as it's
upgraded to AppleShare Client 3.8.5 or later.  (And you want 3.8.6 to
fix a bug that'll crash you if you type a bad username or password during
DHX authentication.)

Suddenly DHX looks much more useful than I thought it was.

---

From: Ron Chmara <[email-masked]>
Date: Mon, 31 Jul 2000 13:59:01 -0700

> the "cleartext password" notice shows up next to the username/password

"With clues" is an important qualifier. :-)

> and it might be time for a global password change.

Or that the server is just "doing something funny"....and "needs to be
rebooted"... most folks never even look that closely at their prompting.

> chooser since that's coming directly over the appletalk protocol, not IP.

Depends on the OT version... the individual DoS attack details may vary,
but the point is: "take the valid server out of the LAN". Flood ping it,
whatever.

> servers start advertising the same server name?

Nope.

-Bop
--
Brought to you from boop!, the dual boot Linux/Win95 Compaq Presario 1625
laptop, currently running RedHat 6.1. Your bopping may vary.

---

From: Harry Zink/Netatalk List <[email-masked]>
Date: Mon, 31 Jul 2000 17:47:18 -0700

> RPM with a 10-foot pole.  Always get the source, compile and install it

Jeepers.... Maybe I should just create a special list and regularly send the
rant below to all of them to make sure it sinks in. The question was "Any
HOWTO on setting up encrypted passwords well?" could you explain how that
friggin' relates to your answer?

/RANT ON/

yadda, yadda, RPMs are bad, yadda, yadda, only source is good, yadda, yadda,
(insert random "source is the tool of Gods" argument here)

Look, we ALL know the pros and cons of RPMs, but, guess what, there are
specific applications, and some people like to use, surprise, RPMs.

So, since I am probably not the only one who is getting tired by the "RPMs
are all bad" faction, could we please *NOT* use any RPM question that pops
up as a soapbox for a personal vendetta against RPM use. You like to roll
your own - that's great - at least understand (or try to) that not everyone
shares that enthusiasm, or need.

RPMs serve a purpose. People asking questions about RPMs do to get answers,
not useless preachings about the values of source compilings.

/RANT OFF/

a) RPMs, depending on how they are rolled, can be effective tools for
installation, particularly to foster acceptance of packages by newbies.

b) the most popular distros that we want to accept netatalk use RPMs, so
your suggestion of the 'only acceptable choice' is moot.

c) We have an opportunity here to dump the 'you're only good if you can
compile source' egos, and help contribute to make a PRODUCT better - a good
product includes an easy way to install and configure it.

d) We have an opportunity to help make the netatalk RPMs better, and that's
a good thing. self-evangelization does not serve anyone.

Is that clear, or does it need to be repeated?

Harry

---

From: Hauke Fath <[email-masked]>
Date: Tue, 01 Aug 2000 07:55:23 +0200

>friggin' relates to your answer?

[...]

>Is that clear, or does it need to be repeated?

"The Noise of a GNU generation."

Harry,

you have every right to your opinion, but please stop spamming the list.

1) We are talking about the bleeding edge of development here, and anyone 
participating and/or using -current is expected to (be able to) build 
things for himself. This is "netatalk-admins" and not "netatalk-newusers".

2) You are actually provided binary packages as a convenience, but you want 
more: You want binary packages with every odd permutation of compile 
switches. No, you don't want to build them yourself, you want *somebody 
else* to sit down and do the work for you after your spec. This is an Open 
Source project. No-one on the list "owes" you a binary package. Need I say 
more?

3) This is not a vendetta against binary packages, which save work and have 
their place for *stable* source.

My 0,02 Euro.

         hauke

--
Hauke Fath                        Tangro Software Components GmbH
                                         D-69115 Heidelberg
[email-masked]                       Ruf +49-6221-13336-35, Fax -21