大网数据广告活动
服务器运维问答

Disabling GSSAuthentication in sshd_conf has no effect

· 52CE 我爱测

I'm using a fresh install of the most recent build of RockyLinux 9 . I'm trying to disable GSSAPI for SSH based login, along with passwords and permit only public key based login. Setting GSSAPIAuthentication no in sshd_conf does…

问题原文

原帖链接 · David · CC BY-SA 4.0

I'm using a fresh install of the most recent build of RockyLinux 9. I'm trying to disable GSSAPI for SSH based login, along with passwords and permit only public key based login. Setting GSSAPIAuthentication no in sshd_conf doesn't appear to actually disable it, based on the output from the ssh client prompt. Are there any other configuration parameters necessary?

$ grep -i gss /etc/ssh/sshd_config
# GSSAPI options
GSSAPIAuthentication no
#GSSAPICleanupCredentials yes
#GSSAPIStrictAcceptorCheck yes
#GSSAPIKeyExchange no
#GSSAPIEnablek5users no

# service sshd restart

#on an another host
$ ssh [email omitted]
[email omitted]: Permission denied (publickey,gssapi-keyex,gssapi-with-mic).

已采纳解答

原帖链接 · Tomek · CC BY-SA 4.0

What do you have in /etc/ssh/sshd_config.d? 50-redhat.conf seems to enable it and it is included early on. As far as I remember the first occurrence in sshd_config wins.

Following on the comment: please have a look at Include config directive for both ssh_config and sshd_config. It's been there since at least RHEL 8 for ssh_config and was introduced in RHEL 9 for sshd_config.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2023-04-21)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。