Skip to content

Commit e783e8d

Browse files
committed
Merge pull request puppetlabs#1255 from olivierHa/krb_add_params
Add missing parameters in mod_auth_kerb
2 parents 57dbbf4 + 0feea4f commit e783e8d

File tree

4 files changed

+31
-1
lines changed

4 files changed

+31
-1
lines changed

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2074,6 +2074,18 @@ Location of the Kerberos V5 keytab file. Not set by default.
20742074

20752075
Strips @REALM from username for further use. Not set by default.
20762076

2077+
##### `krb_verify_kdc`
2078+
2079+
This option can be used to disable the verification tickets against local keytab to prevent KDC spoofing attacks. Default is 'on'
2080+
2081+
##### `krb_servicename`
2082+
2083+
Specifies the service name that will be used by Apache for authentication. Corresponding key of this name must be stored in the keytab. Default is 'HTTP'
2084+
2085+
##### `krb_save_credentials`
2086+
2087+
This option enables credential saving functionality. Default is 'off'
2088+
20772089
##### `limit_request_field_size`
20782090

20792091
[Limits](http://httpd.apache.org/docs/2.4/mod/core.html#limitrequestfieldsize) the size of the HTTP request header allowed from the client. Default is 'undef'.

manifests/vhost.pp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,9 @@
131131
$krb_auth_realms = [],
132132
$krb_5keytab = undef,
133133
$krb_local_user_mapping = undef,
134+
$krb_verify_kdc = 'on',
135+
$krb_servicename = 'HTTP',
136+
$krb_save_credentials = 'off',
134137
$limit_request_field_size = undef,
135138
) {
136139
# The base class must be included first because it is used by parameter defaults

spec/defines/vhost_spec.rb

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -456,6 +456,12 @@
456456
:content => /^\s+Krb5Keytab\s\/tmp\/keytab5$/)}
457457
it { is_expected.to contain_concat__fragment('rspec.example.com-auth_kerb').with(
458458
:content => /^\s+KrbLocalUserMapping\soff$/)}
459+
it { is_expected.to contain_concat__fragment('rspec.example.com-auth_kerb').with(
460+
:content => /^\s+KrbServiceName\sHTTP$/)}
461+
it { is_expected.to contain_concat__fragment('rspec.example.com-auth_kerb').with(
462+
:content => /^\s+KrbSaveCredentials\soff$/)}
463+
it { is_expected.to contain_concat__fragment('rspec.example.com-auth_kerb').with(
464+
:content => /^\s+KrbVerifyKDC\son$/)}
459465
it { is_expected.to contain_concat__fragment('rspec.example.com-limits').with(
460466
:content => /^\s+LimitRequestFieldSize\s54321$/)}
461467
end

templates/vhost/_auth_kerb.erb

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,16 @@
1717
Krb5Keytab <%= @krb_5keytab %>
1818
<%- end -%>
1919
<%- if @krb_local_user_mapping -%>
20-
KrbLocalUserMapping <%= @krb_local_user_mapping -%>
20+
KrbLocalUserMapping <%= @krb_local_user_mapping %>
21+
<%- end -%>
22+
<%- if @krb_verify_kdc -%>
23+
KrbVerifyKDC <%= @krb_verify_kdc %>
24+
<%- end -%>
25+
<%- if @krb_servicename -%>
26+
KrbServiceName <%= @krb_servicename %>
27+
<%- end -%>
28+
<%- if @krb_save_credentials -%>
29+
KrbSaveCredentials <%= @krb_save_credentials -%>
2130
<%- end -%>
2231

2332
<% end -%>

0 commit comments

Comments
 (0)