xenproxy 1.0.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (298) hide show
  1. xenproxy-1.0.0/LICENSE +19 -0
  2. xenproxy-1.0.0/MANIFEST.in +2 -0
  3. xenproxy-1.0.0/PKG-INFO +229 -0
  4. xenproxy-1.0.0/README.md +152 -0
  5. xenproxy-1.0.0/pyproject.toml +327 -0
  6. xenproxy-1.0.0/setup.cfg +4 -0
  7. xenproxy-1.0.0/xenproxy/__init__.py +0 -0
  8. xenproxy-1.0.0/xenproxy/addonmanager.py +308 -0
  9. xenproxy-1.0.0/xenproxy/addons/__init__.py +69 -0
  10. xenproxy-1.0.0/xenproxy/addons/anticache.py +18 -0
  11. xenproxy-1.0.0/xenproxy/addons/anticomp.py +15 -0
  12. xenproxy-1.0.0/xenproxy/addons/asgiapp.py +144 -0
  13. xenproxy-1.0.0/xenproxy/addons/block.py +48 -0
  14. xenproxy-1.0.0/xenproxy/addons/blocklist.py +81 -0
  15. xenproxy-1.0.0/xenproxy/addons/browser.py +186 -0
  16. xenproxy-1.0.0/xenproxy/addons/clientplayback.py +298 -0
  17. xenproxy-1.0.0/xenproxy/addons/command_history.py +96 -0
  18. xenproxy-1.0.0/xenproxy/addons/comment.py +19 -0
  19. xenproxy-1.0.0/xenproxy/addons/core.py +286 -0
  20. xenproxy-1.0.0/xenproxy/addons/cut.py +176 -0
  21. xenproxy-1.0.0/xenproxy/addons/disable_h2c.py +42 -0
  22. xenproxy-1.0.0/xenproxy/addons/dns_resolver.py +182 -0
  23. xenproxy-1.0.0/xenproxy/addons/dumper.py +427 -0
  24. xenproxy-1.0.0/xenproxy/addons/errorcheck.py +55 -0
  25. xenproxy-1.0.0/xenproxy/addons/eventstore.py +56 -0
  26. xenproxy-1.0.0/xenproxy/addons/export.py +232 -0
  27. xenproxy-1.0.0/xenproxy/addons/firebypass.py +177 -0
  28. xenproxy-1.0.0/xenproxy/addons/intercept.py +63 -0
  29. xenproxy-1.0.0/xenproxy/addons/keepserving.py +54 -0
  30. xenproxy-1.0.0/xenproxy/addons/maplocal.py +151 -0
  31. xenproxy-1.0.0/xenproxy/addons/mapremote.py +68 -0
  32. xenproxy-1.0.0/xenproxy/addons/modifybody.py +86 -0
  33. xenproxy-1.0.0/xenproxy/addons/modifyheaders.py +117 -0
  34. xenproxy-1.0.0/xenproxy/addons/next_layer.py +474 -0
  35. xenproxy-1.0.0/xenproxy/addons/onboarding.py +34 -0
  36. xenproxy-1.0.0/xenproxy/addons/onboardingapp/__init__.py +63 -0
  37. xenproxy-1.0.0/xenproxy/addons/onboardingapp/static/bootstrap.min.css +6 -0
  38. xenproxy-1.0.0/xenproxy/addons/onboardingapp/static/images/favicon.ico +0 -0
  39. xenproxy-1.0.0/xenproxy/addons/onboardingapp/static/images/mitmproxy-long.png +0 -0
  40. xenproxy-1.0.0/xenproxy/addons/onboardingapp/static/shadowfire.css +44 -0
  41. xenproxy-1.0.0/xenproxy/addons/onboardingapp/templates/icons/android-brands.svg +1 -0
  42. xenproxy-1.0.0/xenproxy/addons/onboardingapp/templates/icons/apple-brands.svg +1 -0
  43. xenproxy-1.0.0/xenproxy/addons/onboardingapp/templates/icons/certificate-solid.svg +1 -0
  44. xenproxy-1.0.0/xenproxy/addons/onboardingapp/templates/icons/firefox-browser-brands.svg +1 -0
  45. xenproxy-1.0.0/xenproxy/addons/onboardingapp/templates/icons/linux-brands.svg +1 -0
  46. xenproxy-1.0.0/xenproxy/addons/onboardingapp/templates/icons/windows-brands.svg +1 -0
  47. xenproxy-1.0.0/xenproxy/addons/onboardingapp/templates/index.html +143 -0
  48. xenproxy-1.0.0/xenproxy/addons/onboardingapp/templates/layout.html +27 -0
  49. xenproxy-1.0.0/xenproxy/addons/proxyauth.py +298 -0
  50. xenproxy-1.0.0/xenproxy/addons/proxyserver.py +396 -0
  51. xenproxy-1.0.0/xenproxy/addons/readfile.py +98 -0
  52. xenproxy-1.0.0/xenproxy/addons/save.py +197 -0
  53. xenproxy-1.0.0/xenproxy/addons/savehar.py +312 -0
  54. xenproxy-1.0.0/xenproxy/addons/script.py +228 -0
  55. xenproxy-1.0.0/xenproxy/addons/server_side_events.py +23 -0
  56. xenproxy-1.0.0/xenproxy/addons/serverplayback.py +305 -0
  57. xenproxy-1.0.0/xenproxy/addons/stickyauth.py +38 -0
  58. xenproxy-1.0.0/xenproxy/addons/stickycookie.py +97 -0
  59. xenproxy-1.0.0/xenproxy/addons/strip_dns_https_records.py +37 -0
  60. xenproxy-1.0.0/xenproxy/addons/termlog.py +50 -0
  61. xenproxy-1.0.0/xenproxy/addons/tlsconfig.py +654 -0
  62. xenproxy-1.0.0/xenproxy/addons/update_alt_svc.py +33 -0
  63. xenproxy-1.0.0/xenproxy/addons/upstream_auth.py +62 -0
  64. xenproxy-1.0.0/xenproxy/addons/view.py +749 -0
  65. xenproxy-1.0.0/xenproxy/certs.py +741 -0
  66. xenproxy-1.0.0/xenproxy/command.py +342 -0
  67. xenproxy-1.0.0/xenproxy/command_lexer.py +41 -0
  68. xenproxy-1.0.0/xenproxy/connection.py +359 -0
  69. xenproxy-1.0.0/xenproxy/contentviews/__init__.py +195 -0
  70. xenproxy-1.0.0/xenproxy/contentviews/_api.py +116 -0
  71. xenproxy-1.0.0/xenproxy/contentviews/_compat.py +74 -0
  72. xenproxy-1.0.0/xenproxy/contentviews/_registry.py +73 -0
  73. xenproxy-1.0.0/xenproxy/contentviews/_utils.py +106 -0
  74. xenproxy-1.0.0/xenproxy/contentviews/_view_css.py +76 -0
  75. xenproxy-1.0.0/xenproxy/contentviews/_view_dns.py +53 -0
  76. xenproxy-1.0.0/xenproxy/contentviews/_view_graphql.py +72 -0
  77. xenproxy-1.0.0/xenproxy/contentviews/_view_http3.py +153 -0
  78. xenproxy-1.0.0/xenproxy/contentviews/_view_image/__init__.py +3 -0
  79. xenproxy-1.0.0/xenproxy/contentviews/_view_image/image_parser.py +119 -0
  80. xenproxy-1.0.0/xenproxy/contentviews/_view_image/view.py +57 -0
  81. xenproxy-1.0.0/xenproxy/contentviews/_view_javascript.py +68 -0
  82. xenproxy-1.0.0/xenproxy/contentviews/_view_json.py +31 -0
  83. xenproxy-1.0.0/xenproxy/contentviews/_view_mqtt.py +277 -0
  84. xenproxy-1.0.0/xenproxy/contentviews/_view_multipart.py +32 -0
  85. xenproxy-1.0.0/xenproxy/contentviews/_view_query.py +31 -0
  86. xenproxy-1.0.0/xenproxy/contentviews/_view_raw.py +17 -0
  87. xenproxy-1.0.0/xenproxy/contentviews/_view_socketio.py +98 -0
  88. xenproxy-1.0.0/xenproxy/contentviews/_view_urlencoded.py +33 -0
  89. xenproxy-1.0.0/xenproxy/contentviews/_view_wbxml.py +25 -0
  90. xenproxy-1.0.0/xenproxy/contentviews/_view_xml_html.py +278 -0
  91. xenproxy-1.0.0/xenproxy/contentviews/_view_zip.py +22 -0
  92. xenproxy-1.0.0/xenproxy/contentviews/base.py +129 -0
  93. xenproxy-1.0.0/xenproxy/contrib/README.md +4 -0
  94. xenproxy-1.0.0/xenproxy/contrib/__init__.py +0 -0
  95. xenproxy-1.0.0/xenproxy/contrib/click/LICENSE.BSD-3 +28 -0
  96. xenproxy-1.0.0/xenproxy/contrib/click/__init__.py +159 -0
  97. xenproxy-1.0.0/xenproxy/contrib/imghdr.py +142 -0
  98. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/LICENSE +1 -0
  99. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/README.md +3 -0
  100. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/__init__.py +0 -0
  101. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/dtls_client_hello.ksy +140 -0
  102. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/dtls_client_hello.py +202 -0
  103. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/exif.py +654 -0
  104. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/gif.py +357 -0
  105. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/google_protobuf.py +126 -0
  106. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/ico.py +93 -0
  107. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/jpeg.py +258 -0
  108. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/make.sh +14 -0
  109. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/png.py +527 -0
  110. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/tls_client_hello.ksy +132 -0
  111. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/tls_client_hello.py +189 -0
  112. xenproxy-1.0.0/xenproxy/contrib/kaitaistruct/vlq_base128_le.py +115 -0
  113. xenproxy-1.0.0/xenproxy/contrib/wbxml/ASCommandResponse.py +73 -0
  114. xenproxy-1.0.0/xenproxy/contrib/wbxml/ASWBXML.py +903 -0
  115. xenproxy-1.0.0/xenproxy/contrib/wbxml/ASWBXMLByteQueue.py +102 -0
  116. xenproxy-1.0.0/xenproxy/contrib/wbxml/ASWBXMLCodePage.py +52 -0
  117. xenproxy-1.0.0/xenproxy/contrib/wbxml/GlobalTokens.py +50 -0
  118. xenproxy-1.0.0/xenproxy/contrib/wbxml/InvalidDataException.py +31 -0
  119. xenproxy-1.0.0/xenproxy/contrib/wbxml/__init__.py +0 -0
  120. xenproxy-1.0.0/xenproxy/coretypes/__init__.py +0 -0
  121. xenproxy-1.0.0/xenproxy/coretypes/bidi.py +26 -0
  122. xenproxy-1.0.0/xenproxy/coretypes/multidict.py +206 -0
  123. xenproxy-1.0.0/xenproxy/coretypes/serializable.py +199 -0
  124. xenproxy-1.0.0/xenproxy/ctx.py +14 -0
  125. xenproxy-1.0.0/xenproxy/dns.py +588 -0
  126. xenproxy-1.0.0/xenproxy/eventsequence.py +84 -0
  127. xenproxy-1.0.0/xenproxy/exceptions.py +51 -0
  128. xenproxy-1.0.0/xenproxy/flow.py +288 -0
  129. xenproxy-1.0.0/xenproxy/flowfilter.py +705 -0
  130. xenproxy-1.0.0/xenproxy/hooks.py +95 -0
  131. xenproxy-1.0.0/xenproxy/http.py +1295 -0
  132. xenproxy-1.0.0/xenproxy/io/__init__.py +6 -0
  133. xenproxy-1.0.0/xenproxy/io/compat.py +528 -0
  134. xenproxy-1.0.0/xenproxy/io/har.py +159 -0
  135. xenproxy-1.0.0/xenproxy/io/io.py +114 -0
  136. xenproxy-1.0.0/xenproxy/io/tnetstring.py +261 -0
  137. xenproxy-1.0.0/xenproxy/log.py +246 -0
  138. xenproxy-1.0.0/xenproxy/master.py +145 -0
  139. xenproxy-1.0.0/xenproxy/net/__init__.py +0 -0
  140. xenproxy-1.0.0/xenproxy/net/check.py +43 -0
  141. xenproxy-1.0.0/xenproxy/net/dns/__init__.py +0 -0
  142. xenproxy-1.0.0/xenproxy/net/dns/classes.py +19 -0
  143. xenproxy-1.0.0/xenproxy/net/dns/domain_names.py +169 -0
  144. xenproxy-1.0.0/xenproxy/net/dns/https_records.py +134 -0
  145. xenproxy-1.0.0/xenproxy/net/dns/op_codes.py +27 -0
  146. xenproxy-1.0.0/xenproxy/net/dns/response_codes.py +58 -0
  147. xenproxy-1.0.0/xenproxy/net/dns/types.py +193 -0
  148. xenproxy-1.0.0/xenproxy/net/encoding.py +239 -0
  149. xenproxy-1.0.0/xenproxy/net/free_port.py +25 -0
  150. xenproxy-1.0.0/xenproxy/net/http/__init__.py +0 -0
  151. xenproxy-1.0.0/xenproxy/net/http/cookies.py +387 -0
  152. xenproxy-1.0.0/xenproxy/net/http/headers.py +113 -0
  153. xenproxy-1.0.0/xenproxy/net/http/http1/__init__.py +21 -0
  154. xenproxy-1.0.0/xenproxy/net/http/http1/assemble.py +99 -0
  155. xenproxy-1.0.0/xenproxy/net/http/http1/read.py +308 -0
  156. xenproxy-1.0.0/xenproxy/net/http/multipart.py +95 -0
  157. xenproxy-1.0.0/xenproxy/net/http/status_codes.py +146 -0
  158. xenproxy-1.0.0/xenproxy/net/http/url.py +200 -0
  159. xenproxy-1.0.0/xenproxy/net/http/user_agents.py +60 -0
  160. xenproxy-1.0.0/xenproxy/net/http/validate.py +141 -0
  161. xenproxy-1.0.0/xenproxy/net/local_ip.py +40 -0
  162. xenproxy-1.0.0/xenproxy/net/server_spec.py +85 -0
  163. xenproxy-1.0.0/xenproxy/net/tls.py +330 -0
  164. xenproxy-1.0.0/xenproxy/options.py +249 -0
  165. xenproxy-1.0.0/xenproxy/optmanager.py +637 -0
  166. xenproxy-1.0.0/xenproxy/platform/__init__.py +40 -0
  167. xenproxy-1.0.0/xenproxy/platform/linux.py +33 -0
  168. xenproxy-1.0.0/xenproxy/platform/openbsd.py +2 -0
  169. xenproxy-1.0.0/xenproxy/platform/osx.py +38 -0
  170. xenproxy-1.0.0/xenproxy/platform/pf.py +42 -0
  171. xenproxy-1.0.0/xenproxy/platform/windows.py +599 -0
  172. xenproxy-1.0.0/xenproxy/proxy/__init__.py +20 -0
  173. xenproxy-1.0.0/xenproxy/proxy/commands.py +159 -0
  174. xenproxy-1.0.0/xenproxy/proxy/context.py +58 -0
  175. xenproxy-1.0.0/xenproxy/proxy/events.py +138 -0
  176. xenproxy-1.0.0/xenproxy/proxy/layer.py +340 -0
  177. xenproxy-1.0.0/xenproxy/proxy/layers/__init__.py +27 -0
  178. xenproxy-1.0.0/xenproxy/proxy/layers/dns.py +190 -0
  179. xenproxy-1.0.0/xenproxy/proxy/layers/http/__init__.py +1210 -0
  180. xenproxy-1.0.0/xenproxy/proxy/layers/http/_base.py +61 -0
  181. xenproxy-1.0.0/xenproxy/proxy/layers/http/_events.py +167 -0
  182. xenproxy-1.0.0/xenproxy/proxy/layers/http/_hooks.py +122 -0
  183. xenproxy-1.0.0/xenproxy/proxy/layers/http/_http1.py +502 -0
  184. xenproxy-1.0.0/xenproxy/proxy/layers/http/_http2.py +714 -0
  185. xenproxy-1.0.0/xenproxy/proxy/layers/http/_http3.py +309 -0
  186. xenproxy-1.0.0/xenproxy/proxy/layers/http/_http_h2.py +207 -0
  187. xenproxy-1.0.0/xenproxy/proxy/layers/http/_http_h3.py +321 -0
  188. xenproxy-1.0.0/xenproxy/proxy/layers/http/_upstream_proxy.py +105 -0
  189. xenproxy-1.0.0/xenproxy/proxy/layers/modes.py +303 -0
  190. xenproxy-1.0.0/xenproxy/proxy/layers/quic/__init__.py +41 -0
  191. xenproxy-1.0.0/xenproxy/proxy/layers/quic/_client_hello_parser.py +111 -0
  192. xenproxy-1.0.0/xenproxy/proxy/layers/quic/_commands.py +92 -0
  193. xenproxy-1.0.0/xenproxy/proxy/layers/quic/_events.py +70 -0
  194. xenproxy-1.0.0/xenproxy/proxy/layers/quic/_hooks.py +77 -0
  195. xenproxy-1.0.0/xenproxy/proxy/layers/quic/_raw_layers.py +433 -0
  196. xenproxy-1.0.0/xenproxy/proxy/layers/quic/_stream_layers.py +638 -0
  197. xenproxy-1.0.0/xenproxy/proxy/layers/tcp.py +143 -0
  198. xenproxy-1.0.0/xenproxy/proxy/layers/tls.py +692 -0
  199. xenproxy-1.0.0/xenproxy/proxy/layers/udp.py +132 -0
  200. xenproxy-1.0.0/xenproxy/proxy/layers/websocket.py +272 -0
  201. xenproxy-1.0.0/xenproxy/proxy/mode_servers.py +546 -0
  202. xenproxy-1.0.0/xenproxy/proxy/mode_specs.py +336 -0
  203. xenproxy-1.0.0/xenproxy/proxy/server.py +610 -0
  204. xenproxy-1.0.0/xenproxy/proxy/server_hooks.py +76 -0
  205. xenproxy-1.0.0/xenproxy/proxy/tunnel.py +201 -0
  206. xenproxy-1.0.0/xenproxy/proxy/utils.py +68 -0
  207. xenproxy-1.0.0/xenproxy/py.typed +0 -0
  208. xenproxy-1.0.0/xenproxy/script/__init__.py +5 -0
  209. xenproxy-1.0.0/xenproxy/script/concurrent.py +32 -0
  210. xenproxy-1.0.0/xenproxy/tcp.py +75 -0
  211. xenproxy-1.0.0/xenproxy/test/taddons.py +82 -0
  212. xenproxy-1.0.0/xenproxy/test/tflow.py +300 -0
  213. xenproxy-1.0.0/xenproxy/test/tutils.py +95 -0
  214. xenproxy-1.0.0/xenproxy/tls.py +152 -0
  215. xenproxy-1.0.0/xenproxy/tools/__init__.py +0 -0
  216. xenproxy-1.0.0/xenproxy/tools/cmdline.py +152 -0
  217. xenproxy-1.0.0/xenproxy/tools/console/__init__.py +3 -0
  218. xenproxy-1.0.0/xenproxy/tools/console/commander/__init__.py +0 -0
  219. xenproxy-1.0.0/xenproxy/tools/console/commander/commander.py +260 -0
  220. xenproxy-1.0.0/xenproxy/tools/console/commandexecutor.py +35 -0
  221. xenproxy-1.0.0/xenproxy/tools/console/commands.py +156 -0
  222. xenproxy-1.0.0/xenproxy/tools/console/common.py +863 -0
  223. xenproxy-1.0.0/xenproxy/tools/console/consoleaddons.py +763 -0
  224. xenproxy-1.0.0/xenproxy/tools/console/defaultkeys.py +277 -0
  225. xenproxy-1.0.0/xenproxy/tools/console/eventlog.py +63 -0
  226. xenproxy-1.0.0/xenproxy/tools/console/flowdetailview.py +149 -0
  227. xenproxy-1.0.0/xenproxy/tools/console/flowlist.py +108 -0
  228. xenproxy-1.0.0/xenproxy/tools/console/flowview.py +497 -0
  229. xenproxy-1.0.0/xenproxy/tools/console/grideditor/__init__.py +29 -0
  230. xenproxy-1.0.0/xenproxy/tools/console/grideditor/base.py +469 -0
  231. xenproxy-1.0.0/xenproxy/tools/console/grideditor/col_bytes.py +49 -0
  232. xenproxy-1.0.0/xenproxy/tools/console/grideditor/col_subgrid.py +40 -0
  233. xenproxy-1.0.0/xenproxy/tools/console/grideditor/col_text.py +48 -0
  234. xenproxy-1.0.0/xenproxy/tools/console/grideditor/col_viewany.py +34 -0
  235. xenproxy-1.0.0/xenproxy/tools/console/grideditor/editors.py +220 -0
  236. xenproxy-1.0.0/xenproxy/tools/console/help.py +113 -0
  237. xenproxy-1.0.0/xenproxy/tools/console/keybindings.py +163 -0
  238. xenproxy-1.0.0/xenproxy/tools/console/keymap.py +262 -0
  239. xenproxy-1.0.0/xenproxy/tools/console/layoutwidget.py +40 -0
  240. xenproxy-1.0.0/xenproxy/tools/console/master.py +263 -0
  241. xenproxy-1.0.0/xenproxy/tools/console/options.py +272 -0
  242. xenproxy-1.0.0/xenproxy/tools/console/overlay.py +195 -0
  243. xenproxy-1.0.0/xenproxy/tools/console/palettes.py +546 -0
  244. xenproxy-1.0.0/xenproxy/tools/console/quickhelp.py +191 -0
  245. xenproxy-1.0.0/xenproxy/tools/console/searchable.py +89 -0
  246. xenproxy-1.0.0/xenproxy/tools/console/signals.py +66 -0
  247. xenproxy-1.0.0/xenproxy/tools/console/statusbar.py +366 -0
  248. xenproxy-1.0.0/xenproxy/tools/console/tabs.py +58 -0
  249. xenproxy-1.0.0/xenproxy/tools/console/window.py +318 -0
  250. xenproxy-1.0.0/xenproxy/tools/dump.py +26 -0
  251. xenproxy-1.0.0/xenproxy/tools/main.py +190 -0
  252. xenproxy-1.0.0/xenproxy/tools/web/__init__.py +3 -0
  253. xenproxy-1.0.0/xenproxy/tools/web/app.py +939 -0
  254. xenproxy-1.0.0/xenproxy/tools/web/index.html +16 -0
  255. xenproxy-1.0.0/xenproxy/tools/web/master.py +122 -0
  256. xenproxy-1.0.0/xenproxy/tools/web/static/favicon.ico +0 -0
  257. xenproxy-1.0.0/xenproxy/tools/web/static/fontawesome-webfont-B-jkhYfk.woff2 +0 -0
  258. xenproxy-1.0.0/xenproxy/tools/web/static/fontawesome-webfont-CDK5bt4p.woff +0 -0
  259. xenproxy-1.0.0/xenproxy/tools/web/static/fontawesome-webfont-CQDK8MU3.ttf +0 -0
  260. xenproxy-1.0.0/xenproxy/tools/web/static/fontawesome-webfont-D13rzr4g.svg +2671 -0
  261. xenproxy-1.0.0/xenproxy/tools/web/static/fontawesome-webfont-G5YE5S7X.eot +0 -0
  262. xenproxy-1.0.0/xenproxy/tools/web/static/index-Be7e-cwP.js +10 -0
  263. xenproxy-1.0.0/xenproxy/tools/web/static/index-DhPPoJ7G.css +1 -0
  264. xenproxy-1.0.0/xenproxy/tools/web/static/vendor-BS4xPthR.js +62 -0
  265. xenproxy-1.0.0/xenproxy/tools/web/static/vendor-Cg3S-P9H.css +1 -0
  266. xenproxy-1.0.0/xenproxy/tools/web/static_viewer.py +118 -0
  267. xenproxy-1.0.0/xenproxy/tools/web/templates/login.html +35 -0
  268. xenproxy-1.0.0/xenproxy/tools/web/web_columns.py +15 -0
  269. xenproxy-1.0.0/xenproxy/tools/web/webaddons.py +150 -0
  270. xenproxy-1.0.0/xenproxy/types.py +497 -0
  271. xenproxy-1.0.0/xenproxy/udp.py +72 -0
  272. xenproxy-1.0.0/xenproxy/utils/__init__.py +0 -0
  273. xenproxy-1.0.0/xenproxy/utils/arg_check.py +167 -0
  274. xenproxy-1.0.0/xenproxy/utils/asyncio_utils.py +100 -0
  275. xenproxy-1.0.0/xenproxy/utils/data.py +37 -0
  276. xenproxy-1.0.0/xenproxy/utils/debug.py +131 -0
  277. xenproxy-1.0.0/xenproxy/utils/emoji.py +1893 -0
  278. xenproxy-1.0.0/xenproxy/utils/htpasswd.py +81 -0
  279. xenproxy-1.0.0/xenproxy/utils/human.py +99 -0
  280. xenproxy-1.0.0/xenproxy/utils/magisk.py +112 -0
  281. xenproxy-1.0.0/xenproxy/utils/pyinstaller/__init__.py +7 -0
  282. xenproxy-1.0.0/xenproxy/utils/pyinstaller/hook-xenproxy.addons.onboardingapp.py +3 -0
  283. xenproxy-1.0.0/xenproxy/utils/pyinstaller/hook-xenproxy.py +1 -0
  284. xenproxy-1.0.0/xenproxy/utils/pyinstaller/hook-xenproxy.tools.web.py +3 -0
  285. xenproxy-1.0.0/xenproxy/utils/signals.py +137 -0
  286. xenproxy-1.0.0/xenproxy/utils/sliding_window.py +32 -0
  287. xenproxy-1.0.0/xenproxy/utils/spec.py +21 -0
  288. xenproxy-1.0.0/xenproxy/utils/strutils.py +291 -0
  289. xenproxy-1.0.0/xenproxy/utils/typecheck.py +72 -0
  290. xenproxy-1.0.0/xenproxy/utils/vt_codes.py +60 -0
  291. xenproxy-1.0.0/xenproxy/version.py +57 -0
  292. xenproxy-1.0.0/xenproxy/websocket.py +182 -0
  293. xenproxy-1.0.0/xenproxy.egg-info/PKG-INFO +229 -0
  294. xenproxy-1.0.0/xenproxy.egg-info/SOURCES.txt +296 -0
  295. xenproxy-1.0.0/xenproxy.egg-info/dependency_links.txt +1 -0
  296. xenproxy-1.0.0/xenproxy.egg-info/entry_points.txt +7 -0
  297. xenproxy-1.0.0/xenproxy.egg-info/requires.txt +31 -0
  298. xenproxy-1.0.0/xenproxy.egg-info/top_level.txt +1 -0
xenproxy-1.0.0/LICENSE ADDED
@@ -0,0 +1,19 @@
1
+ Copyright (c) 2013, Aldo Cortesi. All rights reserved.
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy
4
+ of this software and associated documentation files (the "Software"), to deal
5
+ in the Software without restriction, including without limitation the rights
6
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7
+ copies of the Software, and to permit persons to whom the Software is
8
+ furnished to do so, subject to the following conditions:
9
+
10
+ The above copyright notice and this permission notice shall be included in
11
+ all copies or substantial portions of the Software.
12
+
13
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
19
+ SOFTWARE.
@@ -0,0 +1,2 @@
1
+ graft xenproxy
2
+ recursive-exclude * *.pyc *.pyo *.swo *.swp *.map
@@ -0,0 +1,229 @@
1
+ Metadata-Version: 2.4
2
+ Name: xenproxy
3
+ Version: 1.0.0
4
+ Summary: xenproxy - Free Fire optimized MITM proxy (fork of mitmproxy).
5
+ Author: 1nOnlySahil
6
+ License: Copyright (c) 2013, Aldo Cortesi. All rights reserved.
7
+
8
+ Permission is hereby granted, free of charge, to any person obtaining a copy
9
+ of this software and associated documentation files (the "Software"), to deal
10
+ in the Software without restriction, including without limitation the rights
11
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
12
+ copies of the Software, and to permit persons to whom the Software is
13
+ furnished to do so, subject to the following conditions:
14
+
15
+ The above copyright notice and this permission notice shall be included in
16
+ all copies or substantial portions of the Software.
17
+
18
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
21
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
23
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
24
+ SOFTWARE.
25
+
26
+ Project-URL: Homepage, https://github.com/1nOnlySahil/xenproxy
27
+ Project-URL: Source, https://github.com/1nOnlySahil/xenproxy/
28
+ Project-URL: Issues, https://github.com/1nOnlySahil/xenproxy/issues
29
+ Classifier: License :: OSI Approved :: MIT License
30
+ Classifier: Development Status :: 5 - Production/Stable
31
+ Classifier: Environment :: Console :: Curses
32
+ Classifier: Operating System :: MacOS
33
+ Classifier: Operating System :: POSIX
34
+ Classifier: Operating System :: Microsoft :: Windows
35
+ Classifier: Programming Language :: Python :: 3 :: Only
36
+ Classifier: Programming Language :: Python :: 3.12
37
+ Classifier: Programming Language :: Python :: 3.13
38
+ Classifier: Programming Language :: Python :: 3.14
39
+ Classifier: Programming Language :: Python :: Implementation :: CPython
40
+ Classifier: Topic :: Security
41
+ Classifier: Topic :: Internet :: WWW/HTTP
42
+ Classifier: Topic :: Internet :: Proxy Servers
43
+ Classifier: Topic :: System :: Networking :: Monitoring
44
+ Classifier: Topic :: Software Development :: Testing
45
+ Classifier: Typing :: Typed
46
+ Requires-Python: >=3.12
47
+ Description-Content-Type: text/markdown
48
+ License-File: LICENSE
49
+ Requires-Dist: aioquic<=1.2.0,>=1.2.0
50
+ Requires-Dist: argon2-cffi<=25.1.0,>=23.1.0
51
+ Requires-Dist: asgiref<=3.11.1,>=3.2.10
52
+ Requires-Dist: bcrypt<=5.0.0,>=5.0.0
53
+ Requires-Dist: Brotli<=1.2.0,>=1.0
54
+ Requires-Dist: certifi>=2019.9.11
55
+ Requires-Dist: cryptography<=49.0.0,>=42.0
56
+ Requires-Dist: flask<=3.1.3,>=3.0
57
+ Requires-Dist: h11<=0.16.0,>=0.16.0
58
+ Requires-Dist: h2<=4.3.0,>=4.3.0
59
+ Requires-Dist: hyperframe<=6.1.0,>=6.0
60
+ Requires-Dist: kaitaistruct<=0.11,>=0.10
61
+ Requires-Dist: ldap3<=2.9.1,>=2.8
62
+ Requires-Dist: mitmproxy_rs<0.13,>=0.12.6
63
+ Requires-Dist: msgpack<=1.1.2,>=1.0.0
64
+ Requires-Dist: pydivert<=3.1.1,>=2.0.3; sys_platform == "win32"
65
+ Requires-Dist: pyOpenSSL<=27.0.0,>=24.3
66
+ Requires-Dist: pyparsing<=3.3.2,>=2.4.2
67
+ Requires-Dist: pyperclip<=1.11.0,>=1.9.0
68
+ Requires-Dist: ruamel.yaml<=0.19.1,>=0.18.10
69
+ Requires-Dist: sortedcontainers<=2.4.0,>=2.3
70
+ Requires-Dist: tornado<=6.5.5,>=6.5.0
71
+ Requires-Dist: typing-extensions<=4.14,>=4.13.2; python_version < "3.13"
72
+ Requires-Dist: urwid<=4.0.0,>=2.6.14
73
+ Requires-Dist: wsproto<=1.3.2,>=1.0
74
+ Requires-Dist: publicsuffix2<=2.20191221,>=2.20190812
75
+ Requires-Dist: zstandard<=0.25.0,>=0.25
76
+ Dynamic: license-file
77
+
78
+ # XenProxy
79
+
80
+ A Free Fire-optimized MITM proxy, forked from mitmproxy. XenProxy combines a full-featured HTTPS interception proxy with a dedicated Free Fire bypass pipeline.
81
+
82
+ ## Features
83
+
84
+ ### Core Proxy (forked from mitmproxy)
85
+ - Interactive console UI, headless dump mode, and web UI
86
+ - HTTP/1, HTTP/2, HTTP/3, and WebSocket interception
87
+ - TLS interception with dynamic certificate generation
88
+ - TCP, UDP, and DNS proxy modes
89
+ - Scriptable via Python addons
90
+ - Full mitmproxy addon ecosystem compatibility
91
+
92
+ ### Free Fire Bypass Addon
93
+ - **Login interception** — hooks into Free Fire API domains (`loginbp.ggblueshark.com`, `prod-api.reward.ff.garena.com`, etc.)
94
+ - **UID blocking** — inspect raw TCP streams and block connections by UID
95
+ - **Fingerprint masking** — strips proxy-detection headers (`Via`, `X-Forwarded-For`, etc.) and rewrites User-Agent
96
+ - **JWT forwarding** — integrates with the access_jwt token mutation service
97
+ - **Runtime commands** — `ff.block_uid`, `ff.unblock_uid`, `ff.list_blocked`
98
+
99
+ ### Backend Pipeline
100
+ - Raw TCP forwarder on `:9999` — bidirectional byte-level proxy with game-layer AES decrypt
101
+ - JWT mutation service on `:1080` — template-based protobuf payload rewriting
102
+ - Admin HTTP API on `:5000` — UID management, stats, health checks
103
+ - UID sync loop — pulls blocklists from remote API every 120s
104
+
105
+ ## Architecture
106
+
107
+ ```
108
+ Emulator → Raw Forwarder (:9999) → XenProxy Proxy (:8080) → Game Servers
109
+
110
+ access_jwt Service (:1080)
111
+ (JWT mutation)
112
+ ```
113
+
114
+ ## Quick Start
115
+
116
+ ```bash
117
+ # Install
118
+ pip install xenproxy
119
+
120
+ # Start the proxy
121
+ xenproxy
122
+
123
+ # Start the web UI
124
+ xenproxy web
125
+
126
+ # Start headless dump mode
127
+ xenproxy dump
128
+ ```
129
+
130
+ ### Free Fire Pipeline
131
+
132
+ ```bash
133
+ # Terminal 1: Start the backend services
134
+ cd new/python
135
+ pip install -r requirements.txt
136
+ python main.py
137
+
138
+ # Terminal 2: Start XenProxy with the bypass addon
139
+ xenproxy -s xenproxy/addons/firebypass.py --set ff_bypass=true
140
+ ```
141
+
142
+ Configure your emulator to use the proxy at the host machine's LAN IP on port 8080, and the raw forwarder on port 9999.
143
+
144
+ ## Configuration
145
+
146
+ XenProxy reads `~/.xenproxy/config.yaml` on startup. Key options:
147
+
148
+ | Option | Default | Description |
149
+ |---|---|---|
150
+ | `listen_port` | 8080 | Proxy listen port |
151
+ | `mode` | regular | Proxy mode (regular, transparent, socks5, reverse, upstream) |
152
+ | `ssl_insecure` | false | Disable upstream TLS verification |
153
+ | `ff_bypass` | true | Enable Free Fire bypass addon |
154
+ | `ff_blocked_uids` | [] | UIDs to block |
155
+ | `ff_access_jwt_url` | http://127.0.0.1:1080 | JWT mutation service URL |
156
+ | `ff_mask_fingerprint` | true | Strip proxy fingerprints |
157
+
158
+ ## Building
159
+
160
+ ### PyInstaller (standalone binary)
161
+
162
+ ```bash
163
+ pyinstaller release/specs/standalone.spec --clean
164
+ # Output: release/dist/xenproxy.exe
165
+ ```
166
+
167
+ ### MSIX Installer (Windows Store)
168
+
169
+ ```bash
170
+ pyinstaller release/specs/onedir.spec --clean
171
+ python release/build.py msix-installer
172
+ ```
173
+
174
+ ### InstallBuilder Installer (Windows)
175
+
176
+ ```bash
177
+ pyinstaller release/specs/onedir.spec --clean
178
+ python release/build.py installbuilder-installer
179
+ ```
180
+
181
+ ### Docker
182
+
183
+ ```bash
184
+ docker build -t xenproxy release/docker/
185
+ docker run -p 8080:8080 -p 8081:8081 xenproxy
186
+ ```
187
+
188
+ ## Development
189
+
190
+ ```bash
191
+ # Install with uv
192
+ uv sync
193
+
194
+ # Run tests
195
+ uv run pytest
196
+
197
+ # Run linter
198
+ uv run ruff check xenproxy/
199
+
200
+ # Type check
201
+ uv run mypy xenproxy/
202
+ ```
203
+
204
+ ## Project Structure
205
+
206
+ ```
207
+ xenproxy/ # Main proxy package
208
+ ├── addons/ # Addon modules
209
+ │ ├── firebypass.py # Free Fire bypass addon
210
+ │ └── onboardingapp/ # Certificate installation portal
211
+ ├── proxy/ # Proxy core
212
+ ├── tools/ # CLI entry points
213
+ │ └── main.py # xenproxy_cli dispatcher
214
+ ├── net/ # Network protocols
215
+ ├── io/ # I/O and serialization
216
+ ├── contentviews/ # Content decoders
217
+ └── utils/ # Utilities
218
+ web/ # React/TypeScript web UI frontend
219
+ release/ # Build & installer configs
220
+ new/python/ # Free Fire backend pipeline
221
+ ```
222
+
223
+ ## License
224
+
225
+ MIT — see [LICENSE](./LICENSE).
226
+
227
+ ## Credits
228
+
229
+ XenProxy is a fork of [mitmproxy](https://github.com/mitmproxy/mitmproxy). The original project is maintained by the mitmproxy contributors and licensed under the MIT license.
@@ -0,0 +1,152 @@
1
+ # XenProxy
2
+
3
+ A Free Fire-optimized MITM proxy, forked from mitmproxy. XenProxy combines a full-featured HTTPS interception proxy with a dedicated Free Fire bypass pipeline.
4
+
5
+ ## Features
6
+
7
+ ### Core Proxy (forked from mitmproxy)
8
+ - Interactive console UI, headless dump mode, and web UI
9
+ - HTTP/1, HTTP/2, HTTP/3, and WebSocket interception
10
+ - TLS interception with dynamic certificate generation
11
+ - TCP, UDP, and DNS proxy modes
12
+ - Scriptable via Python addons
13
+ - Full mitmproxy addon ecosystem compatibility
14
+
15
+ ### Free Fire Bypass Addon
16
+ - **Login interception** — hooks into Free Fire API domains (`loginbp.ggblueshark.com`, `prod-api.reward.ff.garena.com`, etc.)
17
+ - **UID blocking** — inspect raw TCP streams and block connections by UID
18
+ - **Fingerprint masking** — strips proxy-detection headers (`Via`, `X-Forwarded-For`, etc.) and rewrites User-Agent
19
+ - **JWT forwarding** — integrates with the access_jwt token mutation service
20
+ - **Runtime commands** — `ff.block_uid`, `ff.unblock_uid`, `ff.list_blocked`
21
+
22
+ ### Backend Pipeline
23
+ - Raw TCP forwarder on `:9999` — bidirectional byte-level proxy with game-layer AES decrypt
24
+ - JWT mutation service on `:1080` — template-based protobuf payload rewriting
25
+ - Admin HTTP API on `:5000` — UID management, stats, health checks
26
+ - UID sync loop — pulls blocklists from remote API every 120s
27
+
28
+ ## Architecture
29
+
30
+ ```
31
+ Emulator → Raw Forwarder (:9999) → XenProxy Proxy (:8080) → Game Servers
32
+
33
+ access_jwt Service (:1080)
34
+ (JWT mutation)
35
+ ```
36
+
37
+ ## Quick Start
38
+
39
+ ```bash
40
+ # Install
41
+ pip install xenproxy
42
+
43
+ # Start the proxy
44
+ xenproxy
45
+
46
+ # Start the web UI
47
+ xenproxy web
48
+
49
+ # Start headless dump mode
50
+ xenproxy dump
51
+ ```
52
+
53
+ ### Free Fire Pipeline
54
+
55
+ ```bash
56
+ # Terminal 1: Start the backend services
57
+ cd new/python
58
+ pip install -r requirements.txt
59
+ python main.py
60
+
61
+ # Terminal 2: Start XenProxy with the bypass addon
62
+ xenproxy -s xenproxy/addons/firebypass.py --set ff_bypass=true
63
+ ```
64
+
65
+ Configure your emulator to use the proxy at the host machine's LAN IP on port 8080, and the raw forwarder on port 9999.
66
+
67
+ ## Configuration
68
+
69
+ XenProxy reads `~/.xenproxy/config.yaml` on startup. Key options:
70
+
71
+ | Option | Default | Description |
72
+ |---|---|---|
73
+ | `listen_port` | 8080 | Proxy listen port |
74
+ | `mode` | regular | Proxy mode (regular, transparent, socks5, reverse, upstream) |
75
+ | `ssl_insecure` | false | Disable upstream TLS verification |
76
+ | `ff_bypass` | true | Enable Free Fire bypass addon |
77
+ | `ff_blocked_uids` | [] | UIDs to block |
78
+ | `ff_access_jwt_url` | http://127.0.0.1:1080 | JWT mutation service URL |
79
+ | `ff_mask_fingerprint` | true | Strip proxy fingerprints |
80
+
81
+ ## Building
82
+
83
+ ### PyInstaller (standalone binary)
84
+
85
+ ```bash
86
+ pyinstaller release/specs/standalone.spec --clean
87
+ # Output: release/dist/xenproxy.exe
88
+ ```
89
+
90
+ ### MSIX Installer (Windows Store)
91
+
92
+ ```bash
93
+ pyinstaller release/specs/onedir.spec --clean
94
+ python release/build.py msix-installer
95
+ ```
96
+
97
+ ### InstallBuilder Installer (Windows)
98
+
99
+ ```bash
100
+ pyinstaller release/specs/onedir.spec --clean
101
+ python release/build.py installbuilder-installer
102
+ ```
103
+
104
+ ### Docker
105
+
106
+ ```bash
107
+ docker build -t xenproxy release/docker/
108
+ docker run -p 8080:8080 -p 8081:8081 xenproxy
109
+ ```
110
+
111
+ ## Development
112
+
113
+ ```bash
114
+ # Install with uv
115
+ uv sync
116
+
117
+ # Run tests
118
+ uv run pytest
119
+
120
+ # Run linter
121
+ uv run ruff check xenproxy/
122
+
123
+ # Type check
124
+ uv run mypy xenproxy/
125
+ ```
126
+
127
+ ## Project Structure
128
+
129
+ ```
130
+ xenproxy/ # Main proxy package
131
+ ├── addons/ # Addon modules
132
+ │ ├── firebypass.py # Free Fire bypass addon
133
+ │ └── onboardingapp/ # Certificate installation portal
134
+ ├── proxy/ # Proxy core
135
+ ├── tools/ # CLI entry points
136
+ │ └── main.py # xenproxy_cli dispatcher
137
+ ├── net/ # Network protocols
138
+ ├── io/ # I/O and serialization
139
+ ├── contentviews/ # Content decoders
140
+ └── utils/ # Utilities
141
+ web/ # React/TypeScript web UI frontend
142
+ release/ # Build & installer configs
143
+ new/python/ # Free Fire backend pipeline
144
+ ```
145
+
146
+ ## License
147
+
148
+ MIT — see [LICENSE](./LICENSE).
149
+
150
+ ## Credits
151
+
152
+ XenProxy is a fork of [mitmproxy](https://github.com/mitmproxy/mitmproxy). The original project is maintained by the mitmproxy contributors and licensed under the MIT license.