<commit_before>---

## https://www.objective-see.com/products/blockblock.html
- set_fact:
    app_name: BlockBlock
    app_url: https://bitbucket.org/objective-see/deploy/downloads/BlockBlock_0.9.7.zip
    app_checksum: 'sha1:6b07d713afd43cb008239906b6b033e3f282a697'

- name: download {{ app_name }}
  get_url:
    url: "{{ app_url }}"
    dest: "{{ install_archives }}/{{ app_url | basename }}"
    mode: '0644'
    checksum: "{{ app_checksum }}"
  become: yes

- name: decompress {{ app_name }}
#  unarchive:
#    src: "{{ install_archives }}/{{ app_url | basename }}"
#    dest: "{{ install_archives }}"
  command: "unzip -d {{ install_archives }} {{ install_archives }}/{{ app_url | basename }}"
  args:
    creates: "{{ install_archives }}/{{ app_name }}.app/Contents/MacOS/{{ app_name }}"
  become: yes

- block:
    - include: "google-santa-whitelist.yml type=hash path={{ item }} action=whitelist match=White"
      with_items:
        - "{{ install_archives }}/{{ app_name }}.app/Contents/MacOS/{{ app_name }}"
  when: harden_darwin_santa is defined and harden_darwin_santa and harden_darwin_santa_mode == 2

## FIXME! always return 'install ok' and rc = 0
- name: install ransomwhere
  command: "{{ install_archives }}/{{ app_name }}.app/Contents/MacOS/{{ app_name }} -install"
  args:
    creates: "/Library/Objective-See/BlockBlock"
  become: yes

- block:
    - include: "google-santa-whitelist.yml type=hash path={{ item }} action=whitelist match=White"
      with_items:
        - "/Library/Objective-See/BlockBlock"
  when: harden_darwin_santa is defined and harden_darwin_santa and harden_darwin_santa_mode == 2

# /Library/Objective-See/BlockBlock/whitelist.plist ?<commit_msg>fix BlockBlock app path<commit_after>---

## https://www.objective-see.com/products/blockblock.html
- set_fact:
    app_name: BlockBlock
    app_url: https://bitbucket.org/objective-see/deploy/downloads/BlockBlock_0.9.7.zip
    app_checksum: 'sha1:6b07d713afd43cb008239906b6b033e3f282a697'

- name: download {{ app_name }}
  get_url:
    url: "{{ app_url }}"
    dest: "{{ install_archives }}/{{ app_url | basename }}"
    mode: '0644'
    checksum: "{{ app_checksum }}"
  become: yes

- name: decompress {{ app_name }}
#  unarchive:
#    src: "{{ install_archives }}/{{ app_url | basename }}"
#    dest: "{{ install_archives }}"
  command: "unzip -d {{ install_archives }} {{ install_archives }}/{{ app_url | basename }}"
  args:
    creates: "{{ install_archives }}/{{ app_name }}_Installer.app/Contents/MacOS/{{ app_name }}"
  become: yes

- block:
    - include: "google-santa-whitelist.yml type=hash path={{ item }} action=whitelist match=White"
      with_items:
        - "{{ install_archives }}/{{ app_name }}_Installer.app/Contents/MacOS/{{ app_name }}"
  when: harden_darwin_santa is defined and harden_darwin_santa and harden_darwin_santa_mode == 2

## FIXME! always return 'install ok' and rc = 0
- name: install {{ app_name }}
  command: "{{ install_archives }}/{{ app_name }}_Installer.app/Contents/MacOS/{{ app_name }} -install"
  args:
    creates: "/Library/Objective-See/BlockBlock"
  become: yes

- block:
    - include: "google-santa-whitelist.yml type=hash path={{ item }} action=whitelist match=White"
      with_items:
        - "/Library/Objective-See/BlockBlock"
  when: harden_darwin_santa is defined and harden_darwin_santa and harden_darwin_santa_mode == 2

# /Library/Objective-See/BlockBlock/whitelist.plist ?
{'fraction_non_alphanumeric': 0.15254730713245998, 'fraction_numerical': 0.022707423580786028, 'mean_word_length': 3.9226361031518624, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7109719', 'n_tokens_mistral': 1293, 'n_tokens_neox': 1258, 'n_words': 231}