Alias table bulk loading
Is there a way to load a table of (hundreds of) aliases onto pfSense via SSH, rather than inserting them one-by-one via the GUI?
KOM last edited by
Use an URL Table Alias.
a million thanks!!!
However, the tables seem to hold only lists of IP addresses. To fully automate the generation of aliases, it would be convenient to upload the alias names as well. Can that be done?
Diag> Backup and Restore > Are: Aliases, make a backup
Then visit the same page and restore the Aliases area. That clobbers any existing aliases but it's the closest you'll get to bulk import from an existing set.
Thank you. That is a possible workaround.
I was thinking that all these lists, rules, etc. are certainly held by pfSense in some database. Might it be possible to directly manipulate the database table with SQL commands?
They are not in a database.
They are in the config.xml file at /cf/conf/config.xml.
You might be able to create one, get the XML format, and then script the creation of other entries then insert them but, all in all, you are probably looking to do something that is outside the scope of what the aliases are designed to handle at present.