SSH: nur Public-Key Verfahren, mit PAM?

FreeBSD, Gentoo, openSUSE, CentOS, Ubuntu, Debian
andreask2
Posts: 696
Joined: 2004-01-27 14:16
Location: Aachen
 

SSH: nur Public-Key Verfahren, mit PAM?

Post by andreask2 »

Hallo!

Ist es nicht möglich, mit

Code: Select all

UsePAM yes
in der /etc/ssh/sshd_config ausschließlich das Public-Key Verfahren zu erlauben?

meine /etc/pam.d/sshd:

Code: Select all

# cat /etc/pam.d/sshd
#%PAM-1.0

auth       required     pam_stack.so service=system-auth
auth       required     pam_shells.so
auth       required     pam_nologin.so
account    required     pam_stack.so service=system-auth
password   required     pam_stack.so service=system-auth
session    required     pam_stack.so service=system-auth


Ich finde bei PAM irgendwie kein Modul dafür. Gibt es das nicht?

Grüße
Andreas
dodolin
Posts: 3840
Joined: 2003-01-21 01:59
Location: Sinsheim/Karlsruhe
 

Re: SSH: nur Public-Key Verfahren, mit PAM?

Post by dodolin »

man sshd_config

Code: Select all

    PAMAuthenticationViaKbdInt
             Specifies whether PAM challenge response authentication is
             allowed. This allows the use of most PAM challenge response
             authentication modules, but it will allow password authentication
             regardless of whether PasswordAuthentication is enabled.

[...]
    PasswordAuthentication
             Specifies whether password authentication is allowed.  The
             default is ``yes''.
[...]
    PubkeyAuthentication
             Specifies whether public key authentication is allowed.  The
             default is ``yes''.  Note that this option applies to protocol
             version 2 only.
HTH.
andreask2
Posts: 696
Joined: 2004-01-27 14:16
Location: Aachen
 

Re: SSH: nur Public-Key Verfahren, mit PAM?

Post by andreask2 »

Also bei mir steht das da nicht drin ;-)

und wenn ich es trotzdem verwende, passiert das:

Code: Select all

# /etc/init.d/sshd restart
 * Stopping sshd...                                                                                [ ok ]
 * Starting sshd...
/etc/ssh/sshd_config line 76: Deprecated option PAMAuthenticationViaKbdInt                         [ ok ]
Gibt es keinen anderen Weg?
andreask2
Posts: 696
Joined: 2004-01-27 14:16
Location: Aachen
 

Re: SSH: nur Public-Key Verfahren, mit PAM?

Post by andreask2 »

oder verwendet Ihr hier alle kein PAM für den sshd?
User avatar
Joe User
Project Manager
Project Manager
Posts: 11186
Joined: 2003-02-27 01:00
Location: Hamburg
 

Re: SSH: nur Public-Key Verfahren, mit PAM?

Post by Joe User »

andreask2 wrote:oder verwendet Ihr hier alle kein PAM für den sshd?
[x] !PAM
PayPal.Me/JoeUserFreeBSD Remote Installation
Wings for LifeWings for Life World Run

„If there’s more than one possible outcome of a job or task, and one
of those outcomes will result in disaster or an undesirable consequence,
then somebody will do it that way.“ -- Edward Aloysius Murphy Jr.
athlux
Posts: 61
Joined: 2004-08-20 13:53
 

Re: SSH: nur Public-Key Verfahren, mit PAM?

Post by athlux »

ChallengeResponseAuthentication no

Dann sollte der ssh nur noch Login per PubKey zulassen.