| Policy |
{{ rule.get_policy_display }}
|
| {{ target.get_type_display }} |
{% if perms.santa.view_target %}
{{ target.identifier }}
{% else %}
{{ target.identifier }}
{% endif %}
{% if target.type == "BINARY" %}
{% for file in target.files %}
- name
- {{ file.name }}
- path
- {{ file.path }}
{% if file.bundle %}
- bundle id
- {{ file.bundle.bundle_id }}
- bundle name
- {{ file.bundle.bundle_name }}
- bundle version
- {{ file.bundle.bundle_version_str }}
{% if file.bundle_path %}
- bundle path
- {{ file.bundle_path }}
{% endif %}
{% endif %}
{% endfor %}
{% endif %}
{% if target.type == "BUNDLE" %}
{% with target.bundle as bundle %}
- id
- {{ bundle.bundle_id }}
- name
- {{ bundle.name }}
- version
- {{ bundle.version_str }}
- binaries
- {{ bundle.binary_targets.count }}
{% endwith %}
{% endif %}
{% if target.type == "CERTIFICATE" %}
{% for cert in target.certificates %}
- common name
- {{ cert.common_name|default:"-" }}
- organization
- {{ cert.organization|default:"-" }}
- organizational_unit
- {{ cert.organizational_unit|default:"-" }}
- validity
- {{ cert.valid_from }} - {{ cert.valid_until }}
{% endfor %}
{% endif %}
{% if target.type == "TEAMID" %}
{% for team_id in target.team_ids %}
- organization
- {{ team_id.organization|default:"-" }}
{% endfor %}
{% endif %}
|
{% if rule.custom_msg %}
| Custom message |
{{ rule.custom_msg }} |
{% endif %}
{% if rule.description %}
| Description |
{{ rule.description|linebreaks }} |
{% endif %}
{% if rule.serial_numbers %}
| Serial number{{ rule.serial_numbers|length|pluralize }} |
{% for serial_number in rule.serial_numbers %}
- {{ serial_number }}
{% endfor %}
|
{% endif %}
{% if rule.excluded_serial_numbers %}
| Excluded serial number{{ rule.excluded_serial_numbers|length|pluralize }} |
{% for serial_number in rule.excluded_serial_numbers %}
- {{ serial_number }}
{% endfor %}
|
{% endif %}
{% if rule.primary_users %}
| Primary user{{ rule.primary_users|length|pluralize }} |
{% for primary_user in rule.primary_users %}
- {{ primary_user }}
{% endfor %}
|
{% endif %}
{% if rule.excluded_primary_users %}
| Excluded primary user{{ rule.excluded_primary_users|length|pluralize }} |
{% for primary_user in rule.excluded_primary_users %}
- {{ primary_user }}
{% endfor %}
|
{% endif %}
{% with rule.tags.count as tag_count %}
{% if tag_count %}
| Tag{{ tag_count|pluralize }} |
{% for tag in rule.tags.all %}
{% inventory_tag tag %}
{% endfor %}
|
{% endif %}
{% endwith %}
{% with rule.excluded_tags.count as excluded_tag_count %}
{% if excluded_tag_count %}
| Excluded tag{{ excluded_tag_count|pluralize }} |
{% for tag in rule.excluded_tags.all %}
{% inventory_tag tag %}
{% endfor %}
|
{% endif %}
{% endwith %}
{% if perms.santa.view_ruleset and rule.ruleset %}
| Ruleset |
{{ rule.ruleset }} |
{% endif %}
{% if not rule.ruleset %}
{% if perms.santa.change_rule or perms.santa.delete_rule %}
{% endif %}
{% endif %}