-
-
Save szemmali/6b2c257f8567cda1dbb92b8e92f3e06c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- name: Workaround for OpenSLP security vulnerability in ESXi 6.7 | |
hosts: all | |
tasks: | |
- name: Stopping the SLP service | |
shell: /etc/init.d/slpd stop | |
register: slpd_stop | |
- name: Print Stopping the SLP service | |
debug: | |
msg: "{{slpd_stop.stdout }}" | |
- name: Disable the SLP service | |
shell: esxcli network firewall ruleset set -r CIMSLP -e 0 | |
- name: change persist across reboots | |
shell: chkconfig slpd off | |
- name: Check if the change is applied across reboots | |
shell: chkconfig --list | grep slpd | |
register: check_change | |
- name: Print the result of change | |
debug: | |
msg: "{{check_change.stdout }}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks for publishing this @szemmali.
For those using transient host architecture with autodeploy which cannot manage SLP and wish to periodically run this, we enhanced this playbook a little