feat: add infrastructure audit and diagnostic helper scripts
This commit is contained in:
26
scripts/inspect_provider_13.py
Normal file
26
scripts/inspect_provider_13.py
Normal file
@@ -0,0 +1,26 @@
|
||||
import urllib.request
|
||||
import ssl
|
||||
import json
|
||||
import sys
|
||||
|
||||
sys.stdout.reconfigure(encoding='utf-8')
|
||||
|
||||
ctx = ssl.create_default_context()
|
||||
ctx.check_hostname = False
|
||||
ctx.verify_mode = ssl.CERT_NONE
|
||||
|
||||
token = "SnarfNetPermanentAutomationToken2026"
|
||||
headers = {
|
||||
"Authorization": f"Bearer {token}",
|
||||
"Content-Type": "application/json"
|
||||
}
|
||||
|
||||
def api_call(url):
|
||||
req = urllib.request.Request(url, headers=headers)
|
||||
with urllib.request.urlopen(req, context=ctx, timeout=8) as resp:
|
||||
return json.loads(resp.read().decode('utf-8'))
|
||||
|
||||
print("=== Provider 13 (Homepage / snarfnet.net) ===")
|
||||
p13 = api_call("https://authentik.snarfnet.net/api/v3/providers/proxy/13/")
|
||||
print(json.dumps(p13, indent=2))
|
||||
|
||||
Reference in New Issue
Block a user