diff --git a/lists/microsoft-office365-ip/lists.json b/lists/microsoft-office365-ip/lists.json new file mode 100644 index 0000000..19a68d0 --- /dev/null +++ b/lists/microsoft-office365-ip/lists.json @@ -0,0 +1,325 @@ +{ + "description": "Office 365 URLs and IP address ranges", + "list": [ + "104.146.128.0/17", + "104.210.208.16/29", + "104.210.48.8/29", + "104.211.16.16/29", + "104.211.48.16/29", + "104.214.107.57/32", + "104.215.11.144/32", + "104.215.62.195/32", + "104.215.96.24/29", + "104.41.13.120/29", + "104.42.230.91/32", + "104.42.72.16/29", + "104.44.218.128/25", + "104.44.254.128/25", + "104.44.255.0/25", + "104.45.208.104/29", + "104.47.0.0/17", + "13.106.4.128/25", + "13.106.56.0/25", + "13.107.128.0/22", + "13.107.136.0/22", + "13.107.140.6/32", + "13.107.18.10/31", + "13.107.3.0/24", + "13.107.6.152/31", + "13.107.6.156/31", + "13.107.6.171/32", + "13.107.64.0/18", + "13.107.7.190/31", + "13.107.9.156/31", + "13.70.151.216/32", + "13.71.127.197/32", + "13.72.245.115/32", + "13.73.1.120/32", + "13.75.126.169/32", + "13.80.125.22/32", + "13.84.178.101/32", + "13.89.240.113/32", + "13.91.91.243/32", + "131.253.33.215/32", + "132.245.0.0/16", + "134.170.116.0/25", + "134.170.165.0/25", + "134.170.172.128/25", + "134.170.200.0/21", + "134.170.208.0/21", + "134.170.67.0/25", + "138.91.237.237/32", + "150.171.32.0/22", + "150.171.40.0/22", + "157.55.130.0/25", + "157.55.145.0/25", + "157.55.155.0/25", + "157.55.227.192/26", + "157.55.45.128/25", + "157.55.59.128/25", + "157.56.151.0/25", + "157.56.58.0/25", + "191.232.0.0/23", + "191.232.2.128/25", + "191.234.140.0/22", + "191.237.248.32/29", + "191.237.252.192/28", + "20.190.128.0/18", + "2001:df0:d9:200::/64", + "204.79.197.215/32", + "23.100.120.64/29", + "23.100.16.168/29", + "23.100.32.136/29", + "23.100.72.32/29", + "23.101.165.168/29", + "23.101.181.128/29", + "23.103.160.0/20", + "2603:1006::/40", + "2603:1010:200::c7/128", + "2603:1010:2::cb/128", + "2603:1016::/40", + "2603:1020:0:7::19c/128", + "2603:1020:0:7::4e1/128", + "2603:1020:200::682f:a0fd/128", + "2603:1020:200::682f:a1d8/128", + "2603:1020:201:2::/64", + "2603:1020:201:3::/64", + "2603:1020:201:9::c6/128", + "2603:1020:201::3c4/128", + "2603:1020:201::5f2/128", + "2603:1020:201:a::2b1/128", + "2603:1020:300::33/128", + "2603:1020:400::26/128", + "2603:1020:600::1d3/128", + "2603:1020:600::21f/128", + "2603:1020:600::a1/128", + "2603:1020:700::1cb/128", + "2603:1020:700::215/128", + "2603:1020:700::a2/128", + "2603:1020:800:2::6/128", + "2603:1020:900::8/128", + "2603:1026:200::/39", + "2603:1026:400::/39", + "2603:1026:600::/44", + "2603:1026:620::/44", + "2603:1026:630::/44", + "2603:1026:800::/44", + "2603:1026:820::/45", + "2603:1026:830::/44", + "2603:1026::/40", + "2603:1027::/48", + "2603:1030:1000::21a/128", + "2603:1030:603::3c9/128", + "2603:1030:603::6a/128", + "2603:1030:603::72/128", + "2603:1030:7::749/128", + "2603:1030:800:5::bfee:ad3c/128", + "2603:1030:a02::118/128", + "2603:1030:a02::367/128", + "2603:1030:f00::17/128", + "2603:1036:200::/40", + "2603:1036:400::/40", + "2603:1036:600::/40", + "2603:1036:800::/38", + "2603:1036::/39", + "2603:1036:c00::/40", + "2603:1037::/48", + "2603:1039:1001::/48", + "2603:1039:e01::/48", + "2603:1040:200::111/128", + "2603:1040:200::325/128", + "2603:1040:200::4f3/128", + "2603:1040:400::2f4/128", + "2603:1040:400::5d/128", + "2603:1040:400::5e/128", + "2603:1040:400::7b/128", + "2603:1040:401::57/128", + "2603:1040:401::597/128", + "2603:1040:401::762/128", + "2603:1040:401::c/128", + "2603:1040:601::1e7/128", + "2603:1040:601::26f/128", + "2603:1040:601::2f/128", + "2603:1040:601::36c/128", + "2603:1040:601::4e/128", + "2603:1040:601::60f/128", + "2603:1040:a01::1e/128", + "2603:1040:c01::28/128", + "2603:1040:e00:1::2f/128", + "2603:1040:f00::1f/128", + "2603:1046:900::/40", + "2603:1046::/37", + "2603:1047:100::/64", + "2603:1047::/48", + "2603:1050:1::cd/128", + "2603:1056:400::/40", + "2603:1056:600::/40", + "2603:1056::/40", + "2603:1057::/48", + "2603:1096:400::/40", + "2603:1096:600::/40", + "2603:1096::/38", + "2603:1096:a00::/39", + "2603:1096:c00::/40", + "2603:10a6:200::/40", + "2603:10a6:400::/40", + "2603:10a6:600::/40", + "2603:10a6:800::/40", + "2603:10d6:200::/40", + "2620:1ec:40::/42", + "2620:1ec:4::152/128", + "2620:1ec:4::153/128", + "2620:1ec:6::/48", + "2620:1ec:8f0::/46", + "2620:1ec:8f8::/46", + "2620:1ec:8fc::6/128", + "2620:1ec:900::/46", + "2620:1ec:908::/46", + "2620:1ec:a92::150/128", + "2620:1ec:a92::152/128", + "2620:1ec:a92::153/128", + "2620:1ec:a92::171/128", + "2620:1ec:c::10/128", + "2620:1ec:c::11/128", + "2620:1ec:d::10/128", + "2620:1ec:d::11/128", + "2801:80:1d0:1c00::/64", + "2a01:111:2003::/48", + "2a01:111:2005:6::/64", + "2a01:111:200a:a::/64", + "2a01:111:202c::/48", + "2a01:111:202d::/48", + "2a01:111:202e::/48", + "2a01:111:202e::156/128", + "2a01:111:202e::190/128", + "2a01:111:202e::191/128", + "2a01:111:2035:8::/64", + "2a01:111:f100:1002::4134:c0cb/128", + "2a01:111:f100:1002::4134:c440/128", + "2a01:111:f100:1002::4134:d93c/128", + "2a01:111:f100:1002::4134:d9ee/128", + "2a01:111:f100:1003::4134:3644/128", + "2a01:111:f100:1003::4134:36d5/128", + "2a01:111:f100:1004::4134:f0c8/128", + "2a01:111:f100:2000::a83e:3019/128", + "2a01:111:f100:2000::a83e:3349/128", + "2a01:111:f100:2002::8975:2c33/128", + "2a01:111:f100:2002::8975:2cbc/128", + "2a01:111:f100:2002::8975:2d11/128", + "2a01:111:f100:2002::8975:2d43/128", + "2a01:111:f100:2002::8975:2d79/128", + "2a01:111:f100:2002::8975:2d92/128", + "2a01:111:f100:2002::8975:2d98/128", + "2a01:111:f100:2002::8975:2da8/128", + "2a01:111:f100:3000::a83e:1a8c/128", + "2a01:111:f100:3002::8987:320c/128", + "2a01:111:f100:3002::8987:342a/128", + "2a01:111:f100:3002::8987:3552/128", + "2a01:111:f100:3002::8987:358e/128", + "2a01:111:f100:4001::4625:609b/128", + "2a01:111:f100:4001::4625:61ea/128", + "2a01:111:f100:4001::4625:a065/128", + "2a01:111:f100:4001::4625:a1e3/128", + "2a01:111:f100:4001::4625:a248/128", + "2a01:111:f100:4001::4625:a4b4/128", + "2a01:111:f100:4002::9d37:c021/128", + "2a01:111:f100:4002::9d37:c08f/128", + "2a01:111:f100:4002::9d37:c11a/128", + "2a01:111:f100:6000::4134:a2af/128", + "2a01:111:f100:6000::4134:a591/128", + "2a01:111:f100:6000::4134:b0ba/128", + "2a01:111:f100:6000::4134:b84b/128", + "2a01:111:f100:7000::6fdd:50bb/128", + "2a01:111:f100:7000::6fdd:568a/128", + "2a01:111:f100:7000::6fdd:6095/128", + "2a01:111:f100:7000::6fdd:682b/128", + "2a01:111:f100:7000::6fdd:699d/128", + "2a01:111:f100:7000::6fdd:6b20/128", + "2a01:111:f100:7000::6fdd:6b76/128", + "2a01:111:f100:7000::6fdd:6cac/128", + "2a01:111:f100:7000::6fdd:6cd5/128", + "2a01:111:f100:7000::6fdd:6fc4/128", + "2a01:111:f100:8000::4134:902e/128", + "2a01:111:f100:8000::4134:941b/128", + "2a01:111:f100:8001::d5c7:8077/128", + "2a01:111:f100:9001::1761:91cb/128", + "2a01:111:f100:9001::1761:9642/128", + "2a01:111:f100:a000::5ef5:581c/128", + "2a01:111:f100:a000::5ef5:6c55/128", + "2a01:111:f100:a001::a83f:5c85/128", + "2a01:111:f100:a004::bfeb:88cf/128", + "2a01:111:f100:a004::bfeb:8aa2/128", + "2a01:111:f100:a004::bfeb:8c89/128", + "2a01:111:f100:a004::bfeb:8cb8/128", + "2a01:111:f100:a004::bfeb:8deb/128", + "2a01:111:f102:8001::1761:4237/128", + "2a01:111:f102:8001::1761:4daf/128", + "2a01:111:f102:8001::1761:4f8a/128", + "2a01:111:f400:7c00::/54", + "2a01:111:f400::/48", + "2a01:111:f402::/48", + "2a01:111:f403::/48", + "2a01:111:f406:1000::/64", + "2a01:111:f406:1004::/64", + "2a01:111:f406:1801::/64", + "2a01:111:f406:1805::/64", + "2a01:111:f406:1::/64", + "2a01:111:f406:2::/64", + "2a01:111:f406:3404::/64", + "2a01:111:f406:8000::/64", + "2a01:111:f406:8801::/64", + "2a01:111:f406:a003::/64", + "2a01:111:f406:c00::/64", + "40.104.0.0/15", + "40.107.0.0/16", + "40.108.128.0/17", + "40.114.120.16/29", + "40.126.0.0/18", + "40.69.185.117/32", + "40.81.156.154/32", + "40.83.127.89/32", + "40.90.218.198/32", + "40.92.0.0/15", + "40.96.0.0/13", + "51.140.155.234/32", + "51.140.203.190/32", + "51.141.51.76/32", + "52.100.0.0/14", + "52.104.0.0/14", + "52.108.0.0/14", + "52.112.0.0/14", + "52.163.126.215/32", + "52.164.121.65/32", + "52.164.124.124/32", + "52.164.127.6/32", + "52.168.128.89/32", + "52.170.21.67/32", + "52.172.185.18/32", + "52.174.56.180/32", + "52.178.161.139/32", + "52.178.94.2/32", + "52.183.75.62/32", + "52.184.165.82/32", + "52.225.223.43/32", + "52.228.25.96/32", + "52.238.106.116/32", + "52.238.119.141/32", + "52.238.78.88/32", + "52.242.23.189/32", + "52.244.160.207/32", + "52.247.150.191/32", + "52.96.0.0/14", + "65.52.1.16/29", + "65.52.193.136/29", + "65.54.170.128/25", + "70.37.154.128/25" + ], + "matching_attributes": [ + "ip-src", + "ip-dst", + "domain|ip" + ], + "name": "List of known Office 365 URLs and IP address ranges", + "type": "cidr", + "version": 20190310 +} diff --git a/lists/microsoft-office365/list.json b/lists/microsoft-office365/list.json index ba6c328..ef6fff2 100644 --- a/lists/microsoft-office365/list.json +++ b/lists/microsoft-office365/list.json @@ -91,318 +91,6 @@ ".windows.net", ".yammer.com", ".yammerusercontent.com", - "104.146.128.0/17", - "104.210.208.16/29", - "104.210.48.8/29", - "104.211.16.16/29", - "104.211.48.16/29", - "104.214.107.57/32", - "104.215.11.144/32", - "104.215.62.195/32", - "104.215.96.24/29", - "104.41.13.120/29", - "104.42.230.91/32", - "104.42.72.16/29", - "104.44.218.128/25", - "104.44.254.128/25", - "104.44.255.0/25", - "104.45.208.104/29", - "104.47.0.0/17", - "13.106.4.128/25", - "13.106.56.0/25", - "13.107.128.0/22", - "13.107.136.0/22", - "13.107.140.6/32", - "13.107.18.10/31", - "13.107.3.0/24", - "13.107.6.152/31", - "13.107.6.156/31", - "13.107.6.171/32", - "13.107.64.0/18", - "13.107.7.190/31", - "13.107.9.156/31", - "13.70.151.216/32", - "13.71.127.197/32", - "13.72.245.115/32", - "13.73.1.120/32", - "13.75.126.169/32", - "13.80.125.22/32", - "13.84.178.101/32", - "13.89.240.113/32", - "13.91.91.243/32", - "131.253.33.215/32", - "132.245.0.0/16", - "134.170.116.0/25", - "134.170.165.0/25", - "134.170.172.128/25", - "134.170.200.0/21", - "134.170.208.0/21", - "134.170.67.0/25", - "138.91.237.237/32", - "150.171.32.0/22", - "150.171.40.0/22", - "157.55.130.0/25", - "157.55.145.0/25", - "157.55.155.0/25", - "157.55.227.192/26", - "157.55.45.128/25", - "157.55.59.128/25", - "157.56.151.0/25", - "157.56.58.0/25", - "191.232.0.0/23", - "191.232.2.128/25", - "191.234.140.0/22", - "191.237.248.32/29", - "191.237.252.192/28", - "20.190.128.0/18", - "2001:df0:d9:200::/64", - "204.79.197.215/32", - "23.100.120.64/29", - "23.100.16.168/29", - "23.100.32.136/29", - "23.100.72.32/29", - "23.101.165.168/29", - "23.101.181.128/29", - "23.103.160.0/20", - "2603:1006::/40", - "2603:1010:200::c7/128", - "2603:1010:2::cb/128", - "2603:1016::/40", - "2603:1020:0:7::19c/128", - "2603:1020:0:7::4e1/128", - "2603:1020:200::682f:a0fd/128", - "2603:1020:200::682f:a1d8/128", - "2603:1020:201:2::/64", - "2603:1020:201:3::/64", - "2603:1020:201:9::c6/128", - "2603:1020:201::3c4/128", - "2603:1020:201::5f2/128", - "2603:1020:201:a::2b1/128", - "2603:1020:300::33/128", - "2603:1020:400::26/128", - "2603:1020:600::1d3/128", - "2603:1020:600::21f/128", - "2603:1020:600::a1/128", - "2603:1020:700::1cb/128", - "2603:1020:700::215/128", - "2603:1020:700::a2/128", - "2603:1020:800:2::6/128", - "2603:1020:900::8/128", - "2603:1026:200::/39", - "2603:1026:400::/39", - "2603:1026:600::/44", - "2603:1026:620::/44", - "2603:1026:630::/44", - "2603:1026:800::/44", - "2603:1026:820::/45", - "2603:1026:830::/44", - "2603:1026::/40", - "2603:1027::/48", - "2603:1030:1000::21a/128", - "2603:1030:603::3c9/128", - "2603:1030:603::6a/128", - "2603:1030:603::72/128", - "2603:1030:7::749/128", - "2603:1030:800:5::bfee:ad3c/128", - "2603:1030:a02::118/128", - "2603:1030:a02::367/128", - "2603:1030:f00::17/128", - "2603:1036:200::/40", - "2603:1036:400::/40", - "2603:1036:600::/40", - "2603:1036:800::/38", - "2603:1036::/39", - "2603:1036:c00::/40", - "2603:1037::/48", - "2603:1039:1001::/48", - "2603:1039:e01::/48", - "2603:1040:200::111/128", - "2603:1040:200::325/128", - "2603:1040:200::4f3/128", - "2603:1040:400::2f4/128", - "2603:1040:400::5d/128", - "2603:1040:400::5e/128", - "2603:1040:400::7b/128", - "2603:1040:401::57/128", - "2603:1040:401::597/128", - "2603:1040:401::762/128", - "2603:1040:401::c/128", - "2603:1040:601::1e7/128", - "2603:1040:601::26f/128", - "2603:1040:601::2f/128", - "2603:1040:601::36c/128", - "2603:1040:601::4e/128", - "2603:1040:601::60f/128", - "2603:1040:a01::1e/128", - "2603:1040:c01::28/128", - "2603:1040:e00:1::2f/128", - "2603:1040:f00::1f/128", - "2603:1046:900::/40", - "2603:1046::/37", - "2603:1047:100::/64", - "2603:1047::/48", - "2603:1050:1::cd/128", - "2603:1056:400::/40", - "2603:1056:600::/40", - "2603:1056::/40", - "2603:1057::/48", - "2603:1096:400::/40", - "2603:1096:600::/40", - "2603:1096::/38", - "2603:1096:a00::/39", - "2603:1096:c00::/40", - "2603:10a6:200::/40", - "2603:10a6:400::/40", - "2603:10a6:600::/40", - "2603:10a6:800::/40", - "2603:10d6:200::/40", - "2620:1ec:40::/42", - "2620:1ec:4::152/128", - "2620:1ec:4::153/128", - "2620:1ec:6::/48", - "2620:1ec:8f0::/46", - "2620:1ec:8f8::/46", - "2620:1ec:8fc::6/128", - "2620:1ec:900::/46", - "2620:1ec:908::/46", - "2620:1ec:a92::150/128", - "2620:1ec:a92::152/128", - "2620:1ec:a92::153/128", - "2620:1ec:a92::171/128", - "2620:1ec:c::10/128", - "2620:1ec:c::11/128", - "2620:1ec:d::10/128", - "2620:1ec:d::11/128", - "2801:80:1d0:1c00::/64", - "2a01:111:2003::/48", - "2a01:111:2005:6::/64", - "2a01:111:200a:a::/64", - "2a01:111:202c::/48", - "2a01:111:202d::/48", - "2a01:111:202e::/48", - "2a01:111:202e::156/128", - "2a01:111:202e::190/128", - "2a01:111:202e::191/128", - "2a01:111:2035:8::/64", - "2a01:111:f100:1002::4134:c0cb/128", - "2a01:111:f100:1002::4134:c440/128", - "2a01:111:f100:1002::4134:d93c/128", - "2a01:111:f100:1002::4134:d9ee/128", - "2a01:111:f100:1003::4134:3644/128", - "2a01:111:f100:1003::4134:36d5/128", - "2a01:111:f100:1004::4134:f0c8/128", - "2a01:111:f100:2000::a83e:3019/128", - "2a01:111:f100:2000::a83e:3349/128", - "2a01:111:f100:2002::8975:2c33/128", - "2a01:111:f100:2002::8975:2cbc/128", - "2a01:111:f100:2002::8975:2d11/128", - "2a01:111:f100:2002::8975:2d43/128", - "2a01:111:f100:2002::8975:2d79/128", - "2a01:111:f100:2002::8975:2d92/128", - "2a01:111:f100:2002::8975:2d98/128", - "2a01:111:f100:2002::8975:2da8/128", - "2a01:111:f100:3000::a83e:1a8c/128", - "2a01:111:f100:3002::8987:320c/128", - "2a01:111:f100:3002::8987:342a/128", - "2a01:111:f100:3002::8987:3552/128", - "2a01:111:f100:3002::8987:358e/128", - "2a01:111:f100:4001::4625:609b/128", - "2a01:111:f100:4001::4625:61ea/128", - "2a01:111:f100:4001::4625:a065/128", - "2a01:111:f100:4001::4625:a1e3/128", - "2a01:111:f100:4001::4625:a248/128", - "2a01:111:f100:4001::4625:a4b4/128", - "2a01:111:f100:4002::9d37:c021/128", - "2a01:111:f100:4002::9d37:c08f/128", - "2a01:111:f100:4002::9d37:c11a/128", - "2a01:111:f100:6000::4134:a2af/128", - "2a01:111:f100:6000::4134:a591/128", - "2a01:111:f100:6000::4134:b0ba/128", - "2a01:111:f100:6000::4134:b84b/128", - "2a01:111:f100:7000::6fdd:50bb/128", - "2a01:111:f100:7000::6fdd:568a/128", - "2a01:111:f100:7000::6fdd:6095/128", - "2a01:111:f100:7000::6fdd:682b/128", - "2a01:111:f100:7000::6fdd:699d/128", - "2a01:111:f100:7000::6fdd:6b20/128", - "2a01:111:f100:7000::6fdd:6b76/128", - "2a01:111:f100:7000::6fdd:6cac/128", - "2a01:111:f100:7000::6fdd:6cd5/128", - "2a01:111:f100:7000::6fdd:6fc4/128", - "2a01:111:f100:8000::4134:902e/128", - "2a01:111:f100:8000::4134:941b/128", - "2a01:111:f100:8001::d5c7:8077/128", - "2a01:111:f100:9001::1761:91cb/128", - "2a01:111:f100:9001::1761:9642/128", - "2a01:111:f100:a000::5ef5:581c/128", - "2a01:111:f100:a000::5ef5:6c55/128", - "2a01:111:f100:a001::a83f:5c85/128", - "2a01:111:f100:a004::bfeb:88cf/128", - "2a01:111:f100:a004::bfeb:8aa2/128", - "2a01:111:f100:a004::bfeb:8c89/128", - "2a01:111:f100:a004::bfeb:8cb8/128", - "2a01:111:f100:a004::bfeb:8deb/128", - "2a01:111:f102:8001::1761:4237/128", - "2a01:111:f102:8001::1761:4daf/128", - "2a01:111:f102:8001::1761:4f8a/128", - "2a01:111:f400:7c00::/54", - "2a01:111:f400::/48", - "2a01:111:f402::/48", - "2a01:111:f403::/48", - "2a01:111:f406:1000::/64", - "2a01:111:f406:1004::/64", - "2a01:111:f406:1801::/64", - "2a01:111:f406:1805::/64", - "2a01:111:f406:1::/64", - "2a01:111:f406:2::/64", - "2a01:111:f406:3404::/64", - "2a01:111:f406:8000::/64", - "2a01:111:f406:8801::/64", - "2a01:111:f406:a003::/64", - "2a01:111:f406:c00::/64", - "40.104.0.0/15", - "40.107.0.0/16", - "40.108.128.0/17", - "40.114.120.16/29", - "40.126.0.0/18", - "40.69.185.117/32", - "40.81.156.154/32", - "40.83.127.89/32", - "40.90.218.198/32", - "40.92.0.0/15", - "40.96.0.0/13", - "51.140.155.234/32", - "51.140.203.190/32", - "51.141.51.76/32", - "52.100.0.0/14", - "52.104.0.0/14", - "52.108.0.0/14", - "52.112.0.0/14", - "52.163.126.215/32", - "52.164.121.65/32", - "52.164.124.124/32", - "52.164.127.6/32", - "52.168.128.89/32", - "52.170.21.67/32", - "52.172.185.18/32", - "52.174.56.180/32", - "52.178.161.139/32", - "52.178.94.2/32", - "52.183.75.62/32", - "52.184.165.82/32", - "52.225.223.43/32", - "52.228.25.96/32", - "52.238.106.116/32", - "52.238.119.141/32", - "52.238.78.88/32", - "52.242.23.189/32", - "52.244.160.207/32", - "52.247.150.191/32", - "52.96.0.0/14", - "65.52.1.16/29", - "65.52.193.136/29", - "65.54.170.128/25", - "70.37.154.128/25", "a.wunderlist.com", "account.activedirectory.windowsazure.com", "account.live.com", @@ -721,11 +409,11 @@ "www.youtube.com" ], "matching_attributes": [ - "ip-src", - "ip-dst", + "domain", "domain|ip", "hostname" ], - "name": "List of known Office 365 URLs and IP address ranges", - "version": 20190309 + "name": "List of known Office 365 URLs address ranges", + "type": "string", + "version": 20190310 } diff --git a/tools/generate-office365.py b/tools/generate-office365.py index 68c67a6..a009836 100755 --- a/tools/generate-office365.py +++ b/tools/generate-office365.py @@ -8,19 +8,35 @@ import datetime url = 'https://endpoints.office.com/endpoints/worldwide?clientrequestid=b10c5ed1-bad1-445f-b386-b919946339a7' r = requests.get(url) service_list = r.json() -l = [] +lurls= [] +lips = [] + for service in service_list: for url in service.get('urls', []): - l.append(url.replace('*', '')) + lurls.append(url.replace('*', '')) for ip in service.get('ips', []): - l.append(ip) + lips.append(ip) + +warninglist = {} +warninglist['name'] = 'List of known Office 365 URLs address ranges' +warninglist['version'] = int(datetime.date.today().strftime('%Y%m%d')) +warninglist['description'] = 'Office 365 URLs and IP address ranges' +warninglist['type'] = 'string' +warninglist['list'] = sorted(set(lurls)) +warninglist['matching_attributes'] = ["domain", "domain|ip", "hostname"] + + +with open('../lists/microsoft-office365/list.json', 'w') as data_file: + json.dump(warninglist, data_file, indent=4, sort_keys=True) warninglist = {} warninglist['name'] = 'List of known Office 365 URLs and IP address ranges' warninglist['version'] = int(datetime.date.today().strftime('%Y%m%d')) warninglist['description'] = 'Office 365 URLs and IP address ranges' -warninglist['list'] = sorted(set(l)) -warninglist['matching_attributes'] = ["ip-src", "ip-dst", "domain|ip", "hostname"] +warninglist['list'] = sorted(set(lips)) +warninglist['type'] = 'cidr' +warninglist['matching_attributes'] = ["ip-src", "ip-dst", "domain|ip"] -with open('../lists/microsoft-office365/list.json', 'w') as data_file: + +with open('../lists/microsoft-office365-ip/lists.json', 'w') as data_file: json.dump(warninglist, data_file, indent=4, sort_keys=True)