Last active
October 7, 2024 01:46
-
-
Save thanch2n/4764fe7de50244c85d2b37ae8e01c1c1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function FindProxyForURL(url, host) { | |
url = url.toLowerCase(); | |
host = host.toLowerCase(); | |
if ( | |
shExpMatch(url, "*gist.github.com*") || | |
shExpMatch(url, "*ipinfo.io*") || | |
shExpMatch(url, "*telegram.org*") || | |
shExpMatch(url, "*whatismyipaddress.com*") || | |
shExpMatch(url, "*whatismyip.com*") || | |
shExpMatch(url, "*linkedin.com*") || | |
shExpMatch(url, "*cedexis.com*") || | |
shExpMatch(url, "*google.com*") || | |
shExpMatch(url, "*gmail.com*") || | |
shExpMatch(url, "*gstatic.com*") || | |
shExpMatch(url, "*fonts.gstatic.com/*") || | |
shExpMatch(url, "*googleusercontent.com*") || | |
shExpMatch(url, "*google-analytics.com*") || | |
shExpMatch(url, "*googleadservices.com*") || | |
shExpMatch(url, "*googleapis.com*") || | |
shExpMatch(url, "*youtube.com*") || | |
shExpMatch(url, "*youtube-nocookie.com*") || | |
shExpMatch(url, "*ytimg.com*") || | |
shExpMatch(url, "*ggpht.com*") || | |
shExpMatch(url, "*vimeo.com*") || | |
shExpMatch(url, "*vimeocdn.com*") || | |
shExpMatch(url, "*googleblog.com*") || | |
shExpMatch(url, "*wikipedia.org*") || | |
shExpMatch(url, "*wikimedia.org*") || | |
shExpMatch(url, "*yahoo.com*") || | |
shExpMatch(url, "*yahoodns.net*") || | |
shExpMatch(url, "*yimg.com*") || | |
shExpMatch(url, "*atwola.com*") || | |
shExpMatch(url, "*exelator.net*") || | |
shExpMatch(url, "*zendesk.com*") || | |
shExpMatch(url, "*adsafeprotected.com*") || | |
shExpMatch(url, "*crwdcntrl.net*") || | |
shExpMatch(url, "*googletagmanager.com*") || | |
shExpMatch(url, "*googlevideo.com*") || | |
shExpMatch(url, "*twitter.com*") || | |
shExpMatch(url, "*twimg.com*") || | |
shExpMatch(url, "*facebook.com*") || | |
shExpMatch(url, "*.*.cdn.whatsapp.net*") || | |
shExpMatch(url, "*g.whatsapp.net*") || | |
shExpMatch(url, "*graph.facebook.com*") || | |
shExpMatch(url, "*graph.whatsapp.com*") || | |
shExpMatch(url, "*media-.*.cdn.whatsapp.net*") || | |
shExpMatch(url, "*media..*.fna.whatsapp.net*") || | |
shExpMatch(url, "*mmg.whatsapp.net*") || | |
shExpMatch(url, "*pps.whatsapp.net*") || | |
shExpMatch(url, "*static.whatsapp.net*") || | |
shExpMatch(url, "*v.whatsapp.net*") || | |
shExpMatch(url, "*googlesyndication.com*") || | |
shExpMatch(url, "*bbc.com*") || | |
shExpMatch(url, "*bbc.co.uk*") || | |
shExpMatch(url, "*bbci.co.uk*") || | |
shExpMatch(url, "*scmp.com*") || | |
shExpMatch(url, "*daum.net*") || | |
shExpMatch(url, "*chat.openai.com*") || | |
shExpMatch(url, "*daumcdn.net*") || | |
shExpMatch(url, "*chrome.com*") || | |
shExpMatch(url, "*whatsapp.com*") || | |
shExpMatch(url, "*wsj.com*") || | |
shExpMatch(url, "*reuters.com*") || | |
shExpMatch(url, "*nikkei.com*") || | |
shExpMatch(url, "*straitstimes.com*") || | |
shExpMatch(url, "*todayonline.com*") || | |
shExpMatch(url, "*googleapps.com*") || | |
shExpMatch(url, "*clients2.google.com*") || | |
shExpMatch(url, "*clients4.google.com*") || | |
shExpMatch(url, "*clients6.google.com*") || | |
shExpMatch(url, "*lh3.googleusercontent.com*") || | |
shExpMatch(url, "*meetings.clients6.google.com*") || | |
shExpMatch(url, "*accounts.google.com*") || | |
shExpMatch(url, "*apis.google.com*") || | |
shExpMatch(url, "*stun.l.google.com*") || | |
shExpMatch(url, "*calendarsync-pa.googleapis.com*") || | |
shExpMatch(url, "*meetings.googleapis.com*") || | |
shExpMatch(url, "*hangouts.googleapis.com*") || | |
shExpMatch(url, "*scone-pa.googleapis.com*") || | |
shExpMatch(url, "*meet.google.com*") || | |
shExpMatch(url, "*apps.google.com*") || | |
shExpMatch(url, "*jamboard.google.com*") || | |
shExpMatch(url, "*docs.google.com*") || | |
shExpMatch(url, "*stream.meet.google.com*") || | |
shExpMatch(url, "*youtube.googleapis.com*") || | |
shExpMatch(url, "*youtube-nocookie.com*") || | |
shExpMatch(url, "*googlevideo.com*") || | |
shExpMatch(url, "*google.com/tools/feedback/**") || | |
shExpMatch(url, "*feedback.googleusercontent.com/resources/**") || | |
shExpMatch(url, "*play.google.com/log/**") || | |
shExpMatch(url, "*spotify.com*") || | |
shExpMatch(url, "*quora.com*") || | |
shExpMatch(url, "*oanda.com*") || | |
shExpMatch(url, "*kakaocorp.com*") || | |
shExpMatch(url, "*kakao.com*") || | |
shExpMatch(url, "*kakaocorpcdn.com*") || | |
shExpMatch(url, "*t1.kakaocdn.net*") || | |
shExpMatch(url, "*t1.daumcdn.net*") || | |
shExpMatch(url, "*daumcdn.net*") || | |
shExpMatch(url, "*pstatic.net*") || | |
shExpMatch(url, "*naver.com*") || | |
shExpMatch(url, "*app.goo.gl*") || | |
shExpMatch(url, "*turns.goog*") || | |
shExpMatch(url, "*db46bf83.web-api.kandji.io*") || | |
shExpMatch(url, "*googelusercontent.com*") || | |
shExpMatch(url, "*thirdbridge.kandji.io*") || | |
shExpMatch(url, "*accounts.google.com*") || | |
shExpMatch(url, "*db46bf83.devices.us-1.kandji.io*") || | |
shExpMatch(url, "*googleapis.com*") || | |
shExpMatch(url, "*thirdbridge.web-api.kandji.io*") || | |
shExpMatch(url, "*gstatic.com*") || | |
shExpMatch(url, "*rtc.iot.kandji.io*") || | |
shExpMatch(url, "*kandji-prd-managed-library-items.s3.amazonaws.com*") || | |
shExpMatch(url, "*thirdbridge.gateway.kandji.io*") || | |
shExpMatch(url, "*auth.kandji.io*") || | |
//shExpMatch(url, "*baincapital.co.jp*") || | |
shExpMatch(url, "*kandji-prd-public.s3.amazonaws.com*") || | |
shExpMatch(url, "*forbes.com*") || | |
shExpMatch(url, "*official-alumni.com*") || | |
shExpMatch(url, "*youtrust.jp*") || | |
shExpMatch(url, "*connect.facebook.net*") || | |
shExpMatch(url, "*docker.com*") || | |
shExpMatch(url, "*dictionary.goo.ne.jp*") || | |
shExpMatch(url, "*licdn.com*") || | |
shExpMatch(url, "*medium.com*") || | |
shExpMatch(url, "*indiatoday.in*") | |
) { | |
return "PROXY 172.28.0.18:3128"; | |
// http_proxy="172.28.0.18:3128" curl -v -I http://www.gstatic.com/generate_204 | |
// curl -v -I http://www.gstatic.com/generate_204 | |
} else { | |
return "SOCKS5 127.0.0.1:6153; DIRECT"; | |
// return "DIRECT"; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment