最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

IP Address Whitelist to Allow WordPress Core Auto Updates

programmeradmin2浏览0评论

I'm working on a site based on a server with quite strict firewall rules. It won't allow anything running on the site to connect an external server unless its IP address is explicitly whitelisted.

Does anyone know where to find the IP address(es) of the WordPress core updater?

Thanks

I'm working on a site based on a server with quite strict firewall rules. It won't allow anything running on the site to connect an external server unless its IP address is explicitly whitelisted.

Does anyone know where to find the IP address(es) of the WordPress core updater?

Thanks

Share Improve this question asked Oct 5, 2020 at 13:53 tw8sw8dw8tw8sw8dw8 733 silver badges10 bronze badges 5
  • There's an old duplicate question here, but that doesn't have an authoritative answer. – Rup Commented Oct 5, 2020 at 14:22
  • In fact you've virtually copied the first paragraph from that question so you must have already seen it? What's going on here? – Rup Commented Oct 5, 2020 at 14:23
  • This address can be a subject to chage time to time, use nslookup downloads.wordpress to check an actual one. – Ivan Shatsky Commented Oct 5, 2020 at 14:48
  • Yes, its because the question and the answers are since 2015. Are these IPs are still the same? I need updated information. – tw8sw8dw8 Commented Oct 5, 2020 at 14:48
  • I think you're going to have to ask wordpress directly for an authoritative answer. You could also try asking your web host if they'll give you a restricted proxy instead, that will allow access to a fixed list of hostnames including downloads.wordpress. – Rup Commented Oct 5, 2020 at 22:04
Add a comment  | 

1 Answer 1

Reset to default 0

Just checked and the IP right now is: 198.143.164.250

Do you want an programmable-in-php way to do it? You could run this on a WP-Cron schedule (adding some code) to check if the IP has changed at all and change it in your firewall if so while deleting the old IP (or use a hook to update the whitelist right before the major update calls all to download the zip). The code will only be as hard as how to whitelist things in your firewall. Hopefully it's something like:

$whitelist_ip = gethostbyname('downloads.wordpress');
add_to_whitelist($whitelist_ip);

Obviously the add_to_whitelist function is hypothetical (a function that either already exists, or you'd need to write) because adding an IP to a firewall depends entirely on what kind of firewall you're using which you may want to edit your original question to explain your firewall and how you add IPs to it.

发布评论

评论列表(0)

  1. 暂无评论