Skip to content

Eel: host for kerberos kdc and ldap#326

Draft
jaysa68 wants to merge 50 commits into
mainfrom
eel
Draft

Eel: host for kerberos kdc and ldap#326
jaysa68 wants to merge 50 commits into
mainfrom
eel

Conversation

@jaysa68
Copy link
Copy Markdown
Member

@jaysa68 jaysa68 commented May 7, 2026

meant to replace our debian host, firestorm.

@jaysa68 jaysa68 changed the title Eel Eel: host for kerberos kdc and ldap May 7, 2026
@jaysa68 jaysa68 force-pushed the eel branch 3 times, most recently from 88deee8 to cdcb775 Compare May 10, 2026 05:09
Copy link
Copy Markdown
Member

@24apricots 24apricots left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is a painful migration. thank you for ur hard work..

Comment thread hosts/servers/eel.nix
ocf.kerberosKdc.enable = true;
ocf.ldapServer.enable = true;

ocf.acme.extraCerts = [
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the extraCerts urls should be passed into a url module options in the respective modules. this would enforce correct behavior as the modules would be able to require that certs are added for ldaps://* to work properly. make sure that the module throws an error when it is enabled without adding a tls cert

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this can be done natively with kerberos, and all clients can enforce passwords by writing to kerberos and handling the error + maybe parsing the policy to get the password requirements.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this does not need to be fixed now and is not a regression. will create an issue

}:

let
cfg = config.ocf.kerberosKdc;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Kdc should be KDC but whatever lol

acl = [
# Staff /admin principals have full KDC access
{
principal = "*/admin";
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we check if a wildcard like this is ok? ocf/puppet explicitly specifies each user's admin and root principal

services.kerberos_server = {
enable = true;
settings = {
kdc.extra-addresses = "127.0.0.2";
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this necessary

Comment thread modules/ldap-server/default.nix
# chatbot) repos anyway, no real reason for it to exist. may
# delete soon anyway.

olcAccess = [
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this config makes me nervous since it is a lot of unnecessary fiddling around from what we know works perfectly. the comments were reworded from puppet, but that aside i think it would be better to just drop https://github.com/ocf/puppet/blob/master/modules/ocf_ldap/templates/slapd.conf.erb in services.openldap.settings.includes, but change anything that needs to be changed (for example tls certs).

};

# The KDC database lives in /var/lib/heimdal/ and must be initialized manually:
# kadmin -l init OCF.BERKELEY.EDU
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i was going to say do this automatically, but i am leaning on letting it fail so that the person deploying knows that they have to either init an empty kdc or migrate. so i think this is ok 👍

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why was this file edited?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why was this file edited?

@24apricots
Copy link
Copy Markdown
Member

24apricots commented May 10, 2026

final sanity checks to do at the final moment after no more changes will be made:

  • check that kerberos and ldap backups work, check the backup diff to see if anything went terribly wrong
  • check reading and writing: kinit, ldapsearch, ldapvi
  • ldapsearch userPassword with gssapi auth (userPassword should only be visible with */admin ticket)
  • account creation
  • keycloak

lets start with migrating nix hosts, then debian hosts. we should do this cautiously

@24apricots 24apricots marked this pull request as draft May 14, 2026 20:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants