Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: add Kerberos authentication #132

Open
Thulium-Drake opened this issue Oct 24, 2023 · 1 comment
Open

Feature request: add Kerberos authentication #132

Thulium-Drake opened this issue Oct 24, 2023 · 1 comment

Comments

@Thulium-Drake
Copy link

Hi there,

In our organization we have Cockpit configured with Kerberos Authentication (https://cockpit-project.org/guide/latest/sso)

Is this something this role can also support?

@Thulium-Drake
Copy link
Author

The tasks we use currently for settings up Kerberos:

- name: 'Ensure Kerberos Principal'
  freeipa.ansible_freeipa.ipaservice:
    name: "HTTP/{{ ansible_facts['fqdn'] }}@{{ ipaclient_domain | upper }}"
    state: 'present'
    ipaadmin_principal: "{{ cockpit_ipa_username }}"
    ipaadmin_password: "{{ cockpit_ipa_password }}"
  delegate_to: "{{ cockpit_ipa_server }}"

- name: 'Retrieve keytab'
  ansible.builtin.shell: |
    kinit -k
    ipa-getkeytab -p HTTP/$(hostname -f)@{{ ipaclient_domain | upper }} -k '/etc/cockpit/krb5.keytab'
  args:
    creates: '/etc/cockpit/krb5.keytab'

- name: 'Ensure keytab ownership/permissions'
  ansible.builtin.file:
    path: '/etc/cockpit/krb5.keytab'
    owner: 'root'
    group: 'root'
    mode: '0400'

Not sure if this is the cleanest way to set it up, but maybe it helps :-)

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

No branches or pull requests

1 participant