diff --git a/lists/microsoft-office365/list.json b/lists/microsoft-office365/list.json index 128d645..3ae723d 100644 --- a/lists/microsoft-office365/list.json +++ b/lists/microsoft-office365/list.json @@ -1,4 +1,5 @@ { + "name": "List of known Office 365 URLs and IP address ranges", "description": "Office 365 URLs and IP address ranges", "list": [ "2a01:111:f406:8800::/64", @@ -1334,5 +1335,6 @@ "216.32.180.0/23", "2a01:111:f400:7c00::/54", "2a01:111:f403::/48" - ] + ], + "version": "20161206" } diff --git a/tools/generate-office365.py b/tools/generate-office365.py index 61db6a8..c3849bd 100644 --- a/tools/generate-office365.py +++ b/tools/generate-office365.py @@ -4,6 +4,7 @@ import requests import xml.etree.ElementTree as ET import json +import datetime url = 'https://support.content.office.net/en-us/static/O365IPAddresses.xml' r = requests.get(url) @@ -13,7 +14,11 @@ for address in office365.iter('address'): l.append(address.text.replace('*', '')) warninglist = {} +warninglist['name'] = 'List of known Office 365 URLs and IP address ranges' +d = datetime.datetime.now() +warninglist['version'] = "{0}{1:02d}{2:02d}".format(d.year, d.month, d.day) warninglist['description'] = 'Office 365 URLs and IP address ranges' warninglist['list'] = l + print (json.dumps(warninglist))