Skip to content

Commit

Permalink
fix: jinja2 templating delimiter unsafe usage (#114)
Browse files Browse the repository at this point in the history
* fix: jinja2 templating delimiter unsafe usage

* fix: additional jinja2 templating delimiters (VIYAARK-301)
  • Loading branch information
kevinlinglesas authored Mar 8, 2024
1 parent 03f0ccc commit e368f6a
Showing 1 changed file with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# Copyright (c) 2019-2020, SAS Institute Inc., Cary, NC, USA. All Rights Reserved.
# Copyright (c) 2019-2024, SAS Institute Inc., Cary, NC, USA. All Rights Reserved.
# SPDX-License-Identifier: Apache-2.0
#
---
Expand Down Expand Up @@ -62,7 +62,7 @@
- name: "Assert that https_proxy is set as environment variable"
assert:
that:
- ("{{ https_proxy }}" != "")
- (https_proxy != "")
msg: |
The environment variable "https_proxy" is not set in environment variables
If your organization uses a forward HTTP proxy server, It should be set as ex.
Expand Down Expand Up @@ -94,7 +94,7 @@
- name: "Assert that http_proxy is set as environment variable"
assert:
that:
- ("{{ http_proxy }}" != "")
- (http_proxy != "")
msg: |
The environment variable "http_proxy" is not set in environment variables
If your organization uses a forward HTTP proxy server, It should be set as ex.
Expand Down Expand Up @@ -127,7 +127,7 @@
- name: "Assert that no_proxy is set as environment variable if https_proxy and http_proxy are set"
assert:
that:
- ((("{{ https_proxy }}" != "" ) and ("{{ http_proxy }}" != "" )) and ("{{ no_proxy }}" != ""))
- ((( https_proxy != "" ) and ( http_proxy != "" )) and ( no_proxy != ""))
msg: |
The environment variable "no_proxy" is not set in environment variables
If your organization uses a forward HTTP proxy server, It should be set as ex.
Expand Down Expand Up @@ -156,7 +156,7 @@
- name: "Assert that proxy is set in yum.conf if https_proxy and http_proxy are set"
assert:
that:
- ("{{ proxy_conf_exists.stdout }}" != "" )
- ( proxy_conf_exists.stdout != "" )
msg:
The variable "proxy" is not set in yum.conf file
when: (https_proxy != "") and (http_proxy != "") and not ansible_check_mode
Expand All @@ -177,7 +177,7 @@
- name: "Assert that proxy_username is set in yum.conf if https_proxy and http_proxy are set"
assert:
that:
- ("{{ proxyuser_conf_exists.stdout }}" != "" )
- ( proxyuser_conf_exists.stdout != "" )
msg:
The variable "proxy_username" is not set in yum.conf file
when: (https_proxy != "") and (http_proxy != "") and not ansible_check_mode
Expand All @@ -198,7 +198,7 @@
- name: "Assert that proxy_password is set in yum.conf if https_proxy and http_proxy are set"
assert:
that:
- ("{{ proxypass_conf_exists.stdout }}" != "" )
- ( proxypass_conf_exists.stdout != "" )
msg:
The variable "proxy_password" is not set in yum.conf file.
when: (https_proxy != "") and (http_proxy != "") and not ansible_check_mode
Expand Down

0 comments on commit e368f6a

Please sign in to comment.