If you have multiple Linux machines you wish to add to your Intruder account, it might help to automate linking them to streamline deployment.
โน๏ธ Note: You'll need to download the Nessus agent from within the Intruder portal or from Tenable and install it on your desired devices before following this guide. For help installing the agent, please check out this article.
Once you have already installed the Nessus Agent onto the desired devices, you can run the script below, which will allow you to link each device to Intruder. Please note you will need to update the following parameters in the script before deploying:
<Intruder_Client_ID>- This is the Prefix as specified in the Mass Deployment modal in the portal
โ<Key>- This is the Key value specified in the in-portal modal:
โ(hostname -s)- This is the name you wish for the device to link to the portal with. Leaving this as(hostname -s)will allow the device to be linked to the portal with the hostname currently configured on the device. If you wish to use something static, you must ensure that each device has a unique name within the script using only alphanumeric characters.
#!/bin/zsh
# unzip location is /var/tmp
# this is a post-install script
/usr/sbin/installer -pkg /var/tmp/Install\ Nessus\ Agent.pkg -target /
/Library/NessusAgent/run/sbin/nessuscli agent link --name=<Intruder_Client_ID>_$(hostname -s) --key=<Key> --cloud exit 0


