This article provides the steps on how to add one or more custom SSH keys to your UniFi access point (UAP) and UniFi switch (USW) hardware. It does not apply to UniFi Security Gateway hardware. The following is performed by adding custom lines to a config.properties file. This method is persistent across reboots, firmware upgrades, and is also provisioned to devices added to the site at a late time.
The file config.properties is used for advanced configurations. For more information on creating the config.properties file, please see our help center article which is found HERE.
To add a custom key you would simply add the following:
You would replace SSH_KEY with desired key in base64 format. It is possible to add more than one key. To add a second key you would add the following:
The system_cfg number will increment with every config line, and the key number increments with every key (right after the 4,5,6 system_cfg lines). Please do take note if you have existing system_cfg lines.
Once you have the customizations written in the config.properties file you have to trigger a provision. It may be easiest to toggle a service like SNMP or syslog.
For reference, we will be adding this to the UI in the future. It is a bit of a lower priority though so these steps can be used until this is added to the UI.