PDA

Archiv verlassen und diese Seite im Standarddesign anzeigen : SSH : Zeitverzögerung beim Login



GreenShadow
06.01.06, 12:08
Hallo zusammen,
ich möchte mich von meiner Windows XP Kiste aus mit Hilfe von Putty auf meinem Server einloggen.

Ich öffne also Putty, wähle von der Liste der gespeicherten Sitzungen den Server aus und bestätige, gebe nach dem "login as:" einen Benutzernamen an und staune, warum es bis zu 5 Sekunden braucht, bis er nach dem Passwort frägt.

Es folgt meine sshd_config


Port 22
Protocol 2

PrintMotd yes
Banner /etc/ssh/banner.txt

IgnoreRhosts yes
IgnoreUserKnownHosts no
RhostsRSAAuthentication no
RSAAuthentication yes
PasswordAuthentication yes

StrictModes yes
PermitRootLogin no
PermitEmptyPasswords no
AllowGroups users

MaxAuthTries 3
LoginGraceTime 50
KeepAlive yes
ClientAliveInterval 100
ClientAliveCountMax 10

SyslogFacility AUTHPRIV
Subsystem sftp /usr/libexec/ssh/sftp-server


Es spielt scheinbar keine Rolle ob ein Banner aktiviert ist oder nicht, das bleibt bei diesen ~5 Sekunden. Der Server ist auch nicht wirklich ausgelastet oder so...

Weiß jemand, woran das liegen kann?

Vielen Dank für eure Antworten :)

derRichard
06.01.06, 13:40
hallo!

klingt nacht dns-problem.
geht in deinem netz dns und auch reverse dns richtig?
versuch mal in der sshd_config "UseDNS no" zu setzen...

hth,
//richard

bla!zilla
06.01.06, 13:46
Check mal deine Logs. Möglicherweise meint der SSHd einen Einbruchsversuch zu erkennen. Liegt zu 99% an der Namensauflösung.

GreenShadow
07.01.06, 01:40
Vielen Dank für eure Antworten, genau daran lag es :)

Ich habe meiner /etc/hosts einfach die IP der Windows Kiste hinzugefügt.
Folgende Zeile in der sshd_conf


UseDNS no

bewirkt übrigens das selbe, ist vielleicht in dem Fall auch die bessere Lösung.

Geht wunderbar, Danke :)

basstscho
28.02.06, 09:16
Hallo zusammen,

ich habe das selbe Problem. Leider finde ich die ssh_config etwas verwirrend, da doch normalerweise Einträge mit # davor auskommentiert sind. Dann hätte die aber saumäßig wneig Einträge :) Ich habe deshalb mal UseDNS no auf alle möglichen weisen eingetragen. Leider hat nichts gebracht. Ich hab immer noch laneg Wartezeiten bisch ich mein Passwort eintippen darf.
Leider hab ich in der man ssh_conf nichts über UseDNS gefunden.
Hier mal die Config: welcher Eintrag ist nun richtig?



# $OpenBSD: ssh_config,v 1.20 2005/01/28 09:45:53 dtucker Exp $

# This is the ssh client system-wide configuration file. See
# ssh_config(5) for more information. This file provides defaults for
# users, and the values can be changed in per-user configuration files
# or on the command line.

# Configuration data is parsed as follows:
# 1. command line options
# 2. user-specific file
# 3. system-wide file
# Any configuration value is only changed the first time it is set.
# Thus, host-specific definitions should be at the beginning of the
# configuration file, and defaults at the end.

# Site-wide defaults for some commonly used options. For a comprehensive
# list of available options, their meanings and defaults, please see the
# ssh_config(5) man page.

Host *
# ForwardAgent no
# ForwardX11 no


# If you do not trust your remote host (or its administrator), you
# should not forward X11 connections to your local X11-display for
# security reasons: Someone stealing the authentification data on the
# remote side (the "spoofed" X-server by the remote sshd) can read your
# keystrokes as you type, just like any other X11 client could do.
# Set this to "no" here for global effect or in your own ~/.ssh/config
# file if you want to have the remote X11 authentification data to
# expire after two minutes after remote login.
ForwardX11Trusted yes

UseDNS no
#UseDNS no
# UseDNS no
# RhostsRSAAuthentication no
# RSAAuthentication yes
# PasswordAuthentication yes
# HostbasedAuthentication no
# BatchMode no
# CheckHostIP yes
# AddressFamily any
# ConnectTimeout 0
# StrictHostKeyChecking ask
# IdentityFile ~/.ssh/identity
# IdentityFile ~/.ssh/id_rsa
# IdentityFile ~/.ssh/id_dsa
# Port 22
# Protocol 2,1
# Cipher 3des
# Ciphers aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour,aes192-cbc,aes256-cbc
# EscapeChar ~
# GSSAPIAuthentication no
# GSSAPIDelegateCredentials no
# Set this to 'yes' to enable support for the deprecated 'gssapi' authentication
# mechanism to OpenSSH 3.8p1. The newer 'gssapi-with-mic' mechanism is included
# in this release. The use of 'gssapi' is deprecated due to the presence of
# potential man-in-the-middle attacks, which 'gssapi-with-mic' is not susceptible to.
# GSSAPIEnableMITMAttack no

# This enables sending locale enviroment variables LC_* LANG, see ssh_config(5).
SendEnv LANG LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE LC_MONETARY LC_MESSAGES
SendEnv LC_PAPER LC_NAME LC_ADDRESS LC_TELEPHONE LC_MEASUREMENT
SendEnv LC_IDENTIFICATION LC_ALL



Ich dank euch jetzt schonma für eure Hilfe,
Grüße Johannes

marce
28.02.06, 09:29
es gibt auch sog. Default-Einstellungen oder nicht zwingend-notwendige Optionen :-)

mit ohne "#" ist richtig, wenn Du es verwenden willst...

basstscho
28.02.06, 09:42
Aha, ok, das hab ich mir schon fast gedacht. Allerdings bringt es nichts. Ich habe immer noch lange Wartezeiten. Kanns noch was anderes sein?

Grüße Johannes