News for hackers. Stuff that matters.
Re:Explain like I’m 5: Kerberos (2013) by feld on Monday June 26, 2017 @06:17PM (#14640836)
All of our linux/freebsd boxes on our network at work must be hooked up to kerberos. most of the day I don't have to type my password for anything HTTP/SSH unless it's for sudo.
Re:Explain like I’m 5: Kerberos (2013) by e12e on Monday June 26, 2017 @06:46PM (#14641054)
How do you integrate kerberos sso and http? Is there web browser support? The last time I looked at this, I could get sso to work with apache on the server side and windows (internet explorer) clients - but for anything else I don't think I got ticket forwarding etc to work? (Granted this is a long while back).

I'd love to hear a few keywords about your stack (heimdal/mit, web server(s), directory server(s) etc)?

Re:Explain like I’m 5: Kerberos (2013) by gerdesj on Monday June 26, 2017 @07:23PM (#14641257)
Have a look at the Arch and Gentoo wikis both have a lot of notes.

I wrote this: https://wiki.gentoo.org/wiki/Kerberos_Windows_Interoperabili... It is a little out of date (I keep the latest set of notes on our corp wiki) but will get you most of the way there. The notes on the Arch wiki also have some quite up to date notes on using pam_mount and getting mount.cifs working with Kerberos (ie I've read the docs and experimented, so you don't have to)

winbindd in Samba 4.x is really rather good and will happily manage the Kerberos side of things for you for a minimal setup cost. If you find yourself following a howto that starts whittering on about using setspn.exe on a DC then run away! I recently noticed that SSSD is available on rather a lot of Linux distros and is well respected. Must have a look.

As I mentioned in another thread there is a lot of support for SSO with Kerberos/GSSAPI in nearly everything you can get your paws on. Even Nagstamon can do it! Chrome on Windows - Group Policy, Chrome or Chromium on Linux - policies in a JSON file in a certain location, Firefox - about:config - you can send out FF settings with a file (can't remember the name), IE - Group Policy. PuTTY for ssh. OpenSSH client and server. Squid. Apache, nginx, IIS all do it.

I login to this laptop using my AD username and password. If the wifi is a bit slow and winbindd can't get to the domain then it uses a cached (cryptographically hashed) version of my password to allow me in or not. When it finds the DC (VPN or LAN) then it is able to fix up my Kerberos ticket cache on my behalf.

I know for a fact (by direct experience) that this all works on Gentoo, Arch and Ubuntu (Xenial and Trusty). Any Unix-alike distro that can run mitkrb or heimdal and Samba 4 should be able to do all of this.

Re:Explain like I’m 5: Kerberos (2013) by noinsight on Tuesday June 27, 2017 @02:14AM (#14642902)
> winbindd ... I recently noticed that SSSD is available on rather a lot of Linux distros and is well respected. Must have a look.

Yeah definitely ditch winbindd and use SSSD. SSSD makes doing this really easy and works really well.

Re:Explain like I’m 5: Kerberos (2013) by jabl on Tuesday June 27, 2017 @02:26AM (#14642934)
Yes. Except on samba servers, on those you really really want to run winbindd.
Re:Explain like I’m 5: Kerberos (2013) by Spivak on Tuesday June 27, 2017 @12:21PM (#14646777)
Are you using Samba as a DC in this situation? Because I can't think of a reason you would have to ditch SSSD to set up file shares.
Re:Explain like I’m 5: Kerberos (2013) by jabl on Tuesday June 27, 2017 @02:40PM (#14648028)
No, just as a AD member server. Without winbindd, samba has to fall back to the libc pam/nss functionality which is not as full-featured as the one provided by winbindd. So there's some performance benefits which might or might not matter for you, but there's also some cases that don't work at all without winbindd; at least we were unable to allow non-domain clients (e.g. personal laptops) access to a smb share without winbindd.

If you dig into this topic you can find mails from samba core devs on samba-technical saying that you REALLY should run winbind for a samba AD member server.

Re:Explain like I’m 5: Kerberos (2013) by 0x6019 on Tuesday June 27, 2017 @04:59AM (#14643495)
We use Keycloak (hooked up to FreeIPA) which will try to authenticate against Kerberos and then fall back to a regular login screen or a cookie for more limited SSO. The actual web apps are configured with OpenID Connect or SAML and don't know anything about Kerberos.
Re:Explain like I’m 5: Kerberos (2013) by emmelaich on Tuesday June 27, 2017 @07:25PM (#14650511)
http://www.keycloak.org/ looks fantastic.

btw, https doesn't work, the cert indicates github

Re:Explain like I’m 5: Kerberos (2013) by icebraining on Tuesday June 27, 2017 @07:24AM (#14644312)
Keycloak is interesting, thanks.
Re:Explain like I’m 5: Kerberos (2013) by feld on Wednesday June 28, 2017 @10:55AM (#14654638)
FreeBSD, OpenSSH, Apache mod_kerb2 (and mod_auth_ldap for authorization), Active Directory.

1. install server

2. msktutil tool joins machine to domain (simple tool; no dependencies) and now you have /etc/krb5.keytab file

3. minor configuration for base OS -- LDAP using keytab instead of bind user with static password, etc

4. webservers just need an HTTP principal keytab created (simple msktutil command, then extract it from the /etc/krb5.keytab file into a file apache can read/write)

5. I can ssh to every server without a password after running "kinit" on my macbook

6. it just works and it's reliable, time tested, and secure.

Re:Explain like I’m 5: Kerberos (2013) by vog on Monday June 26, 2017 @06:22PM (#14640879)
Interesting! Why did your company choose Kerberos over, say, SSL/SMIME certificates?

(Honest question, because I had the impression that typically, companies base their PKI on SMIME certificates, because it is easier to setup than an OpenPGP based PKI, and because these certs are supported by most email clients out of the box, in addition to HTTPS and SSH.)

Re:Explain like I’m 5: Kerberos (2013) by gerdesj on Monday June 26, 2017 @06:55PM (#14641105)
I'm only chiming in here because we do the same. We have an AD! Bizarrely it is actually rather easy to use despite the nightmare of rubbish docs on t'internets. We use winbindd (SSSD is another well respected option - must try it) and the algorithmic idmap backend which guarantees the same uid/gid on all Linux boxes. winbindd also sorts out Kerberos keytabs for the machine itself ("join the domain") and logged in used via winbind's NSS and PAM add ons. Finally, winbind can cache logins for offline logins which is nice for say this laptop that I am using right now.

All browsers that I use (IE, Chrom{e|ium}, Firefox) support GSSAPI. Apache, IIS, nginx support GSSAPI. OpenSSH and PuTTY support GSSAPI. There is a lot of support for it out there. Oh and of course Squid for all your proxy needs and HAProxy works as expected (I use it to front Exchange to get PCI DSS compliance even for Exchange 2010 - but that is more a TLS thing). Evolution EWS works through that lot using Kerberos for auth for the full Exchange client experience, including calendaring, without needing Outlook.

Kerb is for auth whereas SSL is for encryption. I think you may be confusing use cases a bit. To be fair all that stuff can be a bit confusing and there is a lot of overlap. SSL can be used for identity proof (often proof by assertion) and so can Kerberos (proof by faith in the rest of your realm)

Re:Explain like I’m 5: Kerberos (2013) by TheDauthi on Monday June 26, 2017 @09:50PM (#14641984)
SSSD has been really, REALLY good to my group... except during initial setup. The logging failed me several times in trying to track down problems. The biggest one was when one of the our sysadmins had mistyped "default". Everything appeared to be connecting, getting data from LDAP... and then SSSD would crash with an empty log file.

It worked fine on all of our other machines with the incorrect spelling. The versions of Debian and SSSD were the same. I assume some library was different, but I never found it. I eventually noticed the typo, fixed it, and everything started working.

That was a couple of years ago. After those initial debugging hurdles, it has "just worked" through upgrades and major software changes.

I'm probably jinxing it by praising it. I'm now expecting SSH to stop working on every machine.

Re:Explain like I’m 5: Kerberos (2013) by jabl on Tuesday June 27, 2017 @02:22AM (#14642925)
Trust me, setting up sssd with debug logging etc. is like the second coming of Jebus compared to ye olde school way of doing it with pam_krb5 + nss_ldap..
Re:Explain like I’m 5: Kerberos (2013) by lstamour on Monday June 26, 2017 @06:38PM (#14641007)
Can't say either way, but after spending a few minutes Googling S/MIME support, it seems completely incompatible with most web browsers and web email services. The only exception appears to be Office 365 with Internet Explorer on Windows? While end-to-end encryption of emails is nice, I'm not sure the benefits outweigh the drawbacks, unless required by regulation. It'd be nice if more webmail providers and browser makers supported S/MIME, especially considering new privacy rules in the EU...