Whilst you are correct I can use the url of the remote site in the IPsec peer configuration, unfortunatly the SA Dst Address has to be an IP address and you are unable to use a urlI do not think you need this script, just use address=urlofremote instead of address=ip