Skip to content

Commit

Permalink
Update _access.conf
Browse files Browse the repository at this point in the history
the pass_auth and satisfy_any properties and now boolean true/false, they do not == 1 so the switching in this template breaks
  • Loading branch information
chrismaffey authored Oct 24, 2024
1 parent ee41bb5 commit dad8d0c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions backend/templates/_access.conf
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
auth_basic "Authorization required";
auth_basic_user_file /data/access/{{ access_list_id }};

{% if access_list.pass_auth == 0 %}
{% if access_list.pass_auth == 0 or access_list.pass_auth == true %}
proxy_set_header Authorization "";
{% endif %}

Expand All @@ -17,7 +17,7 @@
deny all;

# Access checks must...
{% if access_list.satisfy_any == 1 %}
{% if access_list.satisfy_any == 1 or access_list.satisfy_any == true %}
satisfy any;
{% else %}
satisfy all;
Expand Down

2 comments on commit dad8d0c

@Gabri3lZ
Copy link

Choose a reason for hiding this comment

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

@chrismaffey Thank you for the "satisfy_any" fix. The "pass_auth" check is flipped though. Should be "pass_auth == false".

@mordyovits
Copy link

Choose a reason for hiding this comment

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

@chrismaffey Thank you for the "satisfy_any" fix. The "pass_auth" check is flipped though. Should be "pass_auth == false".

That seems pretty serious.

Please sign in to comment.