• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • We are looking for U.S.-based freelancer or agency working with SEO or WordPress for a quick 30-min interviews to gather feedback on XOVI, a successful German SEO tool we’re looking to launch in the U.S.
    If you qualify and participate, you’ll receive a $30 Amazon gift card as a thank-you. Please apply here. Thanks for helping shape a better SEO product for agencies!
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.

Question add IP Addresses to the Firewall module in bulk using import and export function?

nikketrikke

Basic Pleskian
Hello
iI need to add ip address for cdn to be whitelisted on firewall
so
I created a rule for cdn ip list with 2 enters on firewall... then exported via json the firewall rules and named file (original to have as backup)...then using a text editor like Notepad++ I search where the 2 addresses listed are and simply put one by one comma separated all the address i need to whitelist...saved json file
then imported again the modified file (json) into firewall and seems all rules are a their position loaded correctly
Possible so simple????
How can i check if that addresses are correctly whitelisted? there is a shh command to view

iptables -L INPUT -v -n | less

i tried and some addresses are listed not the ip6 exadecimal address
thanks
 
If you want to list all IPv6 rules you have to use the ip6tables utility instead. For example: ip6tables -L INPUT -v -n | less

Also, on a side note, manually exporting, editing and importing firewall rules seems kinda time consuming, There are CLI command to manage firewall rules too. Which might be an easier way to bulk add IP address to rules. More info can be found here: https://support.plesk.com/hc/en-us/...rules-using-Plesk-Firewall-in-Plesk-for-Linux
 
If you want to list all IPv6 rules you have to use the ip6tables utility instead. For example: ip6tables -L INPUT -v -n | less

Also, on a side note, manually exporting, editing and importing firewall rules seems kinda time consuming, There are CLI command to manage firewall rules too. Which might be an easier way to bulk add IP address to rules. More info can be found here: https://support.plesk.com/hc/en-us/...rules-using-Plesk-Firewall-in-Plesk-for-Linux
thanks for the suggestion I see ip6tables ...
i know how to add single rule as in your link but the problem is adding many ip address one by one... my trick of exporting modify and importing json is for adding in bulk so many ip addresses... i not found a real answer in this forum or over the web
only one answer in a ver difficult way...
my solution seems so simple but i notknow if correct due it is so intuitive but never reported here or on the web
can you tell me if correct
 
not seems correct it does not works...
i make another workaround using CSF firewall and make a batch with a allow.txt file with all ip addresses... csf puts in iptables correctly..
then switch off CSF (due it send me a tons of email by LFD not solved) so i enable CSF and use it only to add in batch neww ip addresses then switch off again..
 
Back
Top