From owner-freebsd-questions@freebsd.org Wed Jan 25 09:58:28 2017 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CDD42CB5399 for ; Wed, 25 Jan 2017 09:58:28 +0000 (UTC) (envelope-from carlopmart@gmail.com) Received: from mail-wm0-x231.google.com (mail-wm0-x231.google.com [IPv6:2a00:1450:400c:c09::231]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 5A8F3E3 for ; Wed, 25 Jan 2017 09:58:28 +0000 (UTC) (envelope-from carlopmart@gmail.com) Received: by mail-wm0-x231.google.com with SMTP id c206so21242040wme.0 for ; Wed, 25 Jan 2017 01:58:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=v9cLRjqY3BTAwORqeU91HAExk3ngDkRv6kNDu7ExFTs=; b=miYfhwlxT/s7OtULYJKWzZfWVRGsP9FWZ2Es701iUvXiOhPAMu6Rw29t3ly1aHcBCr vagCA+2MaiAfPasF+nQsctZ4ZjQwWmwGNP5zvrV0PkL0i2uHntbtwmigAflfAE1/tdT9 TiFVy+Utk6vYtDBGgNa4usfSKPAKkAoEXGEbS1lynt81iVrn6vyoi7pBieuCtqumyBNr bzB1Q5A4GNy0ddmqLTWDdxtLDndmUPNtFu3npCpmd6wV0u8iNdXLQJ+lO2/g9skAlmAO FYJ/NoGy9EcyqjJ2gw6OtOc8R6nESIXG9fa0LsYjfeh1bhT1HrEjwJ8LerDm/6LhcxUB 6aBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=v9cLRjqY3BTAwORqeU91HAExk3ngDkRv6kNDu7ExFTs=; b=e4rjI4Fg33MoOV4sXeTNN7dnljh5pt9tlBLPtTDc/yEo7TQTkPvf2lEOgD3DtBMV+0 yCXn71yOQ9li6DOq1i811TjLiI0rmpU7fXpll+TIyApZSaUUHYCbdsszdbPbQz2E1yz5 MSm1BxiaolZy2B0MbNXgVmRQEoxgu4nEGpX7BddPCkStugXUIb+Pftoa/frvjN9E13hD CT18TKMRWVy5VY6WDA8Ri11R6at4D3iD2kI0Mr8I9uEvBw+H75wDRCUuFg8CFKojLbl9 4f6dMez54EamuXd/+gR7bLzDdeb3yOrrRkzNNVJ7RSaGtRLFc/VFCPhJsvNWx2gSRrJ7 p5aA== X-Gm-Message-State: AIkVDXKzwNOkjJbnjYy74cS1LbkJ0Ie6weSh05SyMSG5rnHx0K8/Js66pAGJ3+OgFA+Riw== X-Received: by 10.28.141.78 with SMTP id p75mr20428082wmd.114.1485338306615; Wed, 25 Jan 2017 01:58:26 -0800 (PST) Received: from localhost (23.red-81-35-47.dynamicip.rima-tde.net. [81.35.47.23]) by smtp.gmail.com with ESMTPSA id l37sm19789995wrc.41.2017.01.25.01.58.26 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 25 Jan 2017 01:58:26 -0800 (PST) Date: Wed, 25 Jan 2017 09:58:24 +0000 From: "C. L. Martinez" To: freebsd-questions@freebsd.org Subject: Re: SSH with kerberos auth doesn't provide a ticket Message-ID: <20170125095824.keq3yeu56ewjgh4l@stonehaven.uxdom.org> References: <20170125072552.wrcbygdm6rbxtkhy@stonehaven.uxdom.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20161126 (1.7.1) X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Jan 2017 09:58:28 -0000 On Tue, Jan 24, 2017 at 11:45:30PM -0800, Matt Mullins wrote: > On Tue, Jan 24, 2017 at 11:25 PM, C. L. Martinez wrote: > > Hi all, > > > > I have a strange problem with ssh when kerberos auth is used. We have three kerberos servers based on MIT kerberos. I have configured a FreeBSD 11-RELEASE virtual guest to authenticate against these kerberos servers. Auth works ok, but ssh doesn't request a kerberos ticket (I am connecting from a Windows 10 workstation with putty): > > When you say "auth works ok", I assume that means that PuTTY does not > prompt for a password? If it does prompt for a password, you are > definitely not using GSSAPI at the ssh-connection layer (even if that > password is being checked against a KDC on the ssh server). > > > I have enabled th following options in sshd_config: > > > > # Kerberos options > > KerberosAuthentication yes > > You probably don't need that, if you've got mod_krb5.so in your PAM > config. This only applies when PasswordAuthentication is negotiated > for an SSH session, anyway. > > > It is strange because this "problem" only appears with FreeBSD, all others linux doesn't have this problem. > > > > What am I doing wrong? > > When you configure your PuTTY connection for your FreeBSD machine, > make sure you check the "Allow GSSAPI credential delegation" in > Connection -> SSH -> Auth -> GSSAPI. Seems to work for me. Thanks Matt for your answer. But it is not a problem with PuTTY. Using default config that comes with putty, when I do a ssh login to a CentOS or RHEL server with kerberos auth enabled, ticket is requested and works. Maybe is a problem with my PAM's config. /etc/pam.d/system # # $FreeBSD$ # # System-wide defaults # # auth auth sufficient pam_opie.so no_warn no_fake_prompts auth requisite pam_opieaccess.so no_warn allow_local auth sufficient pam_krb5.so no_warn try_first_pass #auth sufficient pam_ssh.so no_warn try_first_pass auth required pam_unix.so no_warn try_first_pass nullok # account account required pam_krb5.so account required pam_login_access.so account required pam_unix.so # session #session optional pam_ssh.so want_agent session required pam_lastlog.so no_fail # password password sufficient pam_krb5.so no_warn try_first_pass password required pam_unix.so no_warn try_first_pass and /etc/pam.d/sshd # # $FreeBSD$ # # PAM configuration for the "sshd" service # # auth auth sufficient pam_opie.so no_warn no_fake_prompts auth requisite pam_opieaccess.so no_warn allow_local auth sufficient pam_krb5.so no_warn try_first_pass #auth sufficient pam_ssh.so no_warn try_first_pass auth required pam_unix.so no_warn try_first_pass # account account required pam_nologin.so #account required pam_krb5.so account required pam_login_access.so account required pam_unix.so # session #session optional pam_ssh.so want_agent session required pam_permit.so # password password sufficient pam_krb5.so no_warn try_first_pass password required pam_unix.so no_warn try_first_pass -- Greetings, C. L. Martinez