diff --git a/README.md b/README.md index d9d606b..5baf9a9 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ You can use this list one of two ways: There is a cache_domains.json file to define CDNs and additional meta deta with the following structure - cache_domains: Array of cache_domain object - - name: shortname for the cache domain + - name: shortname for the cache domain. Should match `^[0-9A-Za-z]$` - description: a longer description to aid others in identifying what this domain does (not all users of this repo will want to enable all caches) - notes: implementation specific notes which may be useful for other users - mixed_content: true if this domain hosts mixed https and http content (a straight dns injection is unlikely to work in this case). Assumed to be false if undefined @@ -43,6 +43,7 @@ There is a separate file for each cacheable service. Some notes on formatting: - Wildcards are permitted as per below - Lines starting with a # will be treated as a comment. - Files must end with an empty newline. + - File names must match the regular expression `^[0-9A-Za-z].txt` #### Wildcards diff --git a/apple.txt b/apple.txt index 7af9799..ef90914 100644 --- a/apple.txt +++ b/apple.txt @@ -1 +1 @@ -swcdn.apple.com \ No newline at end of file +swcdn.apple.com diff --git a/arenanet.txt b/arenanet.txt index d916aaa..19132a1 100644 --- a/arenanet.txt +++ b/arenanet.txt @@ -1,4 +1,4 @@ assetcdn.101.arenanetworks.com assetcdn.102.arenanetworks.com assetcdn.103.arenanetworks.com -live.patcher.bladeandsoul.com \ No newline at end of file +live.patcher.bladeandsoul.com diff --git a/cache_domains.json b/cache_domains.json index 62b33da..9cca89c 100644 --- a/cache_domains.json +++ b/cache_domains.json @@ -20,6 +20,12 @@ "description": "Daybreak games CDN", "domain_files": ["daybreak.txt"] }, + { + "name": "epicgames", + "description": "CDN for Epic Games", + "domain_files": ["epicgames.txt"], + "mixed_content": true + }, { "name": "frontier", "description": "CDN for frontier games", @@ -48,11 +54,11 @@ "mixed_content": true, "domain_files": ["origin.txt"] }, - { - "name": "renegadex", - "description": "CDN for Renegade X", - "domain_files": ["renegadex.txt"] - }, + { + "name": "renegadex", + "description": "CDN for Renegade X", + "domain_files": ["renegadex.txt"] + }, { "name": "riot", "description": "CDN for riot games", @@ -78,6 +84,12 @@ "description": "CDN for uplay downloader", "domain_files": ["uplay.txt"] }, + { + "name": "teso", + "description": "CDN for The Elder Scrolls Online", + "mixed_content": true, + "domain_files": ["teso.txt"] + }, { "name": "twitch", "description": "CDN for twitch games / mods and addons", @@ -101,4 +113,3 @@ } ] } - diff --git a/epicgames.txt b/epicgames.txt new file mode 100644 index 0000000..9c5b10f --- /dev/null +++ b/epicgames.txt @@ -0,0 +1,5 @@ +epicgames-download1.akamaized.net +download.epicgames.com +download2.epicgames.com +download3.epicgames.com +download4.epicgames.com diff --git a/frontier.txt b/frontier.txt index 1a28124..132127e 100644 --- a/frontier.txt +++ b/frontier.txt @@ -1 +1 @@ -cdn.zaonce.net \ No newline at end of file +cdn.zaonce.net diff --git a/hirez.txt b/hirez.txt index 6dbcbe3..c127b57 100644 --- a/hirez.txt +++ b/hirez.txt @@ -1 +1 @@ -hirez.http.internapcdn.net \ No newline at end of file +hirez.http.internapcdn.net diff --git a/nexusmods.txt b/nexusmods.txt index 2453607..20f38c5 100644 --- a/nexusmods.txt +++ b/nexusmods.txt @@ -1 +1 @@ -filedelivery.nexusmods.com \ No newline at end of file +filedelivery.nexusmods.com diff --git a/renegadex.txt b/renegadex.txt index fa42197..ca35def 100644 --- a/renegadex.txt +++ b/renegadex.txt @@ -9,4 +9,4 @@ rxp-sg.cncirc.net rxp-la.cncirc.net rxp-fin.cncirc.net denver1.renegade-x.com -seattle1.renegade-x.com \ No newline at end of file +seattle1.renegade-x.com diff --git a/rockstar.txt b/rockstar.txt index 9947953..4922bbe 100644 --- a/rockstar.txt +++ b/rockstar.txt @@ -1 +1 @@ -patches.rockstargames.com \ No newline at end of file +patches.rockstargames.com diff --git a/scripts/config.example.json b/scripts/config.example.json index 6d58ee4..18362c4 100644 --- a/scripts/config.example.json +++ b/scripts/config.example.json @@ -1,6 +1,6 @@ { "ips": { - "steam": "10.10.3.11", + "steam": ["10.10.3.10", "10.10.3.11"], "origin": "10.10.3.12", "blizzard": "10.10.3.13", "windows": "10.10.3.14", diff --git a/scripts/create-dnsmasq.sh b/scripts/create-dnsmasq.sh index e0e0d43..c2da94b 100755 --- a/scripts/create-dnsmasq.sh +++ b/scripts/create-dnsmasq.sh @@ -16,7 +16,7 @@ fi cachenamedefault="disabled" while read line; do - ip=$(jq -r ".ips[\"${line}\"]" config.json) + ip=$(jq ".ips[\"${line}\"]" config.json) declare "cacheip$line"="$ip" done <<< $(jq -r '.ips | to_entries[] | .key' config.json) @@ -39,7 +39,7 @@ while read entry; do continue; fi cacheipname="cacheip${!cachename}" - cacheip=${!cacheipname} + cacheip=$(jq -r 'if type == "array" then .[] else . end' <<< ${!cacheipname} | xargs) while read fileid; do while read filename; do destfilename=$(echo $filename | sed -e 's/txt/conf/') @@ -54,7 +54,9 @@ while read entry; do if grep -q "$parsed" $outputfile; then continue fi - echo "address=/${parsed}/${cacheip}" >> $outputfile + for i in ${cacheip}; do + echo "address=/${parsed}/${i}" >> $outputfile + done done <<< $(cat ${basedir}/$filename); done <<< $(jq -r ".cache_domains[$entry].domain_files[$fileid]" $path) done <<< $(jq -r ".cache_domains[$entry].domain_files | to_entries[] | .key" $path) diff --git a/scripts/create-unbound.sh b/scripts/create-unbound.sh index c0d4c0e..10ee026 100755 --- a/scripts/create-unbound.sh +++ b/scripts/create-unbound.sh @@ -16,7 +16,7 @@ fi cachenamedefault="disabled" while read line; do - ip=$(jq -r ".ips[\"${line}\"]" config.json) + ip=$(jq ".ips[\"${line}\"]" config.json) declare "cacheip$line"="$ip" done <<< $(jq -r '.ips | to_entries[] | .key' config.json) @@ -39,7 +39,7 @@ while read entry; do continue; fi cacheipname="cacheip${!cachename}" - cacheip=${!cacheipname} + cacheip=$(jq -r 'if type == "array" then .[] else . end' <<< ${!cacheipname} | xargs) while read fileid; do while read filename; do destfilename=$(echo $filename | sed -e 's/txt/conf/') @@ -56,7 +56,9 @@ while read entry; do continue fi echo " local-zone: \"${parsed}\" redirect" >> $outputfile - echo " local-data: \"${parsed} 30 IN A ${cacheip}\"" >> $outputfile + for i in ${cacheip}; do + echo " local-data: \"${parsed} 30 IN A ${i}\"" >> $outputfile + done done <<< $(cat ${basedir}/$filename); done <<< $(jq -r ".cache_domains[$entry].domain_files[$fileid]" $path) done <<< $(jq -r ".cache_domains[$entry].domain_files | to_entries[] | .key" $path) diff --git a/sony.txt b/sony.txt index 526d08d..4776937 100644 --- a/sony.txt +++ b/sony.txt @@ -1,3 +1,3 @@ pls.patch.station.sony.com gs2.ww.prod.dl.playstation.net -gs2.sonycoment.loris-e.llnwd.net \ No newline at end of file +gs2.sonycoment.loris-e.llnwd.net diff --git a/steam.txt b/steam.txt index ec11673..99f7031 100644 --- a/steam.txt +++ b/steam.txt @@ -18,11 +18,13 @@ steampipe.akamaized.net edgecast.steamstatic.com steam.apac.qtlglb.com.mwcloudcdn.com *.cs.steampowered.com +*.cm.steampowered.com *.edgecast.steamstatic.com *.steamcontent.com cdn1-sea1.valve.net cdn2-sea1.valve.net *.steam-content-dnld-1.apac-1-cdn.cqloud.com +*.steam-content-dnld-1.eu-c1-cdn.cqloud.com steam.apac.qtlglb.com edge.steam-dns.top.comcast.net edge.steam-dns-2.top.comcast.net diff --git a/teso.txt b/teso.txt new file mode 100644 index 0000000..f4b529e --- /dev/null +++ b/teso.txt @@ -0,0 +1 @@ +live.patcher.elderscrollsonline.com diff --git a/wargaming.net.txt b/wargaming.net.txt index a654040..3544bf8 100644 --- a/wargaming.net.txt +++ b/wargaming.net.txt @@ -4,8 +4,16 @@ wg.gcdn.co wgusst-na.wargaming.net wgusst-eu.wargaming.net update-v4r4h10x.worldofwarships.com -dl-wows-ak.wargaming.net wgus-wotasia.wargaming.net dl-wot-ak.wargaming.net dl-wot-gc.wargaming.net +dl-wot-se.wargaming.net dl-wot-cdx.wargaming.net +dl-wows-ak.wargaming.net +dl-wows-gc.wargaming.net +dl-wows-se.wargaming.net +dl-wows-cdx.wargaming.net +dl-wowp-ak.wargaming.net +dl-wowp-gc.wargaming.net +dl-wowp-se.wargaming.net +dl-wowp-cdx.wargaming.net