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

move shib require to top location block #659

Merged
merged 1 commit into from
Feb 14, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 5 additions & 9 deletions manifests/profile/www_lib/vhosts/fulcrum.pp
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,13 @@
String $servername = 'www.fulcrum.org'
) {
$authz_base_requires = {
enforce => 'all',
requires => [
auth_type => 'shibboleth',
custom_fragment => 'ShibRequestSetting requireSession 0',
enforce => 'all',
requires => [
'not env badrobot',
'not env loadbalancer',
'all granted'
'shibboleth'
]
}

Expand Down Expand Up @@ -154,12 +156,6 @@
XSendFile on
XSendFilePath ${derivatives_path}
XSendFilePath ${alt_derivatives_path}
# Configure Shibboleth for authentication via InCommon partner login
<Location "/">
AuthType shibboleth
ShibRequestSetting requireSession 0
Comment on lines -159 to -160
Copy link
Member

Choose a reason for hiding this comment

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

These two lines need to be present in the rendered Location / definition (see the diff I posted in slack). You can do this with an auth_require and custom fragment line, as is done here (ignore the auth_require in that example as that is already covered with the require all definition in this manifest). You can probably make this addition to authz_base_requires.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

auth_require or auth_type... I may have pushed my last commit the opposite. But i'll let you correct me if i'm reading this wrong.

Copy link
Member

Choose a reason for hiding this comment

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

Looks good to me! Go ahead and squash to 1 commit and merge after the tests pass from the squash.

Require shibboleth
</Location>
| EOT
}
}