Whitelist all IP/ Ray Dehler method does not work any longer
You can try below code
var startingPoint = 0;
var endpoint = 0;
openPage();
function openPage()
{
endpoint = startingPoint + 1;
var win = window.open('https://ap2.salesforce.com/05G/e?IpStartAddress=' + startingPoint + '.0.0.0&IpEndAddress=' + endpoint + '.255.255.255&isdtp=vw',600,600);
win.onload = function()
{
win.document.getElementsByName('save')[0].click();
win.onunload = function()
{
win.close();
startingPoint = startingPoint + 2;
if(startingPoint <= 255)
{
openPage();
}
}
}
}
Special thanks to MVP Ankit Arora (Reference:)