2025-12-25 upload
@@ -0,0 +1,63 @@
|
||||
import os
|
||||
|
||||
from flask import Flask
|
||||
from flask import render_template
|
||||
|
||||
from mitmproxy.options import CONF_BASENAME
|
||||
from mitmproxy.options import CONF_DIR
|
||||
from mitmproxy.utils.magisk import write_magisk_module
|
||||
|
||||
app = Flask(__name__)
|
||||
# will be overridden in the addon, setting this here so that the Flask app can be run standalone.
|
||||
app.config["CONFDIR"] = CONF_DIR
|
||||
|
||||
|
||||
@app.route("/")
|
||||
def index():
|
||||
return render_template("index.html")
|
||||
|
||||
|
||||
@app.route("/cert/pem")
|
||||
def pem():
|
||||
return read_cert("pem", "application/x-x509-ca-cert")
|
||||
|
||||
|
||||
@app.route("/cert/p12")
|
||||
def p12():
|
||||
return read_cert("p12", "application/x-pkcs12")
|
||||
|
||||
|
||||
@app.route("/cert/cer")
|
||||
def cer():
|
||||
return read_cert("cer", "application/x-x509-ca-cert")
|
||||
|
||||
|
||||
@app.route("/cert/magisk")
|
||||
def magisk():
|
||||
filename = CONF_BASENAME + f"-magisk-module.zip"
|
||||
p = os.path.join(app.config["CONFDIR"], filename)
|
||||
p = os.path.expanduser(p)
|
||||
|
||||
if not os.path.exists(p):
|
||||
write_magisk_module(p)
|
||||
|
||||
with open(p, "rb") as f:
|
||||
cert = f.read()
|
||||
|
||||
return cert, {
|
||||
"Content-Type": "application/zip",
|
||||
"Content-Disposition": f"attachment; {filename=!s}",
|
||||
}
|
||||
|
||||
|
||||
def read_cert(ext, content_type):
|
||||
filename = CONF_BASENAME + f"-ca-cert.{ext}"
|
||||
p = os.path.join(app.config["CONFDIR"], filename)
|
||||
p = os.path.expanduser(p)
|
||||
with open(p, "rb") as f:
|
||||
cert = f.read()
|
||||
|
||||
return cert, {
|
||||
"Content-Type": content_type,
|
||||
"Content-Disposition": f"attachment; {filename=!s}",
|
||||
}
|
||||
6
venv/Lib/site-packages/mitmproxy/addons/onboardingapp/static/bootstrap.min.css
vendored
Normal file
|
After Width: | Height: | Size: 5.3 KiB |
|
After Width: | Height: | Size: 121 KiB |
@@ -0,0 +1,44 @@
|
||||
.media {
|
||||
min-height: 110px;
|
||||
}
|
||||
.media svg {
|
||||
width: 64px;
|
||||
margin-right: 1rem !important;
|
||||
}
|
||||
|
||||
.instructions {
|
||||
padding-top: 1rem;
|
||||
padding-bottom: 1rem;
|
||||
}
|
||||
|
||||
/* CSS-only collapsible */
|
||||
.show-instructions:target, .hide-instructions, .instructions {
|
||||
display: none;
|
||||
}
|
||||
.show-instructions:target ~ .hide-instructions {
|
||||
display: inline-block;
|
||||
}
|
||||
.show-instructions:target ~ .instructions {
|
||||
display: inherit;
|
||||
}
|
||||
|
||||
.fa-apple {
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.fa-windows {
|
||||
color: #0078D7;
|
||||
}
|
||||
|
||||
.fa-firefox-browser {
|
||||
color: #E25821;
|
||||
}
|
||||
|
||||
.fa-android {
|
||||
margin-top: 10px;
|
||||
color: #3DDC84;
|
||||
}
|
||||
|
||||
.fa-certificate {
|
||||
color: #FFBB00;
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
<svg aria-hidden="true" focusable="false" data-prefix="fab" data-icon="android" class="svg-inline--fa fa-android fa-w-18" role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 576 512"><path fill="currentColor" d="M420.55,301.93a24,24,0,1,1,24-24,24,24,0,0,1-24,24m-265.1,0a24,24,0,1,1,24-24,24,24,0,0,1-24,24m273.7-144.48,47.94-83a10,10,0,1,0-17.27-10h0l-48.54,84.07a301.25,301.25,0,0,0-246.56,0L116.18,64.45a10,10,0,1,0-17.27,10h0l47.94,83C64.53,202.22,8.24,285.55,0,384H576c-8.24-98.45-64.54-181.78-146.85-226.55"></path></svg>
|
||||
|
After Width: | Height: | Size: 535 B |
@@ -0,0 +1 @@
|
||||
<svg aria-hidden="true" focusable="false" data-prefix="fab" data-icon="apple" class="svg-inline--fa fa-apple fa-w-12" role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 384 512"><path fill="currentColor" d="M318.7 268.7c-.2-36.7 16.4-64.4 50-84.8-18.8-26.9-47.2-41.7-84.7-44.6-35.5-2.8-74.3 20.7-88.5 20.7-15 0-49.4-19.7-76.4-19.7C63.3 141.2 4 184.8 4 273.5q0 39.3 14.4 81.2c12.8 36.7 59 126.7 107.2 125.2 25.2-.6 43-17.9 75.8-17.9 31.8 0 48.3 17.9 76.4 17.9 48.6-.7 90.4-82.5 102.6-119.3-65.2-30.7-61.7-90-61.7-91.9zm-56.6-164.2c27.3-32.4 24.8-61.9 24-72.5-24.1 1.4-52 16.4-67.9 34.9-17.5 19.8-27.8 44.3-25.6 71.9 26.1 2 49.9-11.4 69.5-34.3z"></path></svg>
|
||||
|
After Width: | Height: | Size: 665 B |
@@ -0,0 +1 @@
|
||||
<svg aria-hidden="true" focusable="false" data-prefix="fas" data-icon="certificate" class="svg-inline--fa fa-certificate fa-w-16" role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path fill="currentColor" d="M458.622 255.92l45.985-45.005c13.708-12.977 7.316-36.039-10.664-40.339l-62.65-15.99 17.661-62.015c4.991-17.838-11.829-34.663-29.661-29.671l-61.994 17.667-15.984-62.671C337.085.197 313.765-6.276 300.99 7.228L256 53.57 211.011 7.229c-12.63-13.351-36.047-7.234-40.325 10.668l-15.984 62.671-61.995-17.667C74.87 57.907 58.056 74.738 63.046 92.572l17.661 62.015-62.65 15.99C.069 174.878-6.31 197.944 7.392 210.915l45.985 45.005-45.985 45.004c-13.708 12.977-7.316 36.039 10.664 40.339l62.65 15.99-17.661 62.015c-4.991 17.838 11.829 34.663 29.661 29.671l61.994-17.667 15.984 62.671c4.439 18.575 27.696 24.018 40.325 10.668L256 458.61l44.989 46.001c12.5 13.488 35.987 7.486 40.325-10.668l15.984-62.671 61.994 17.667c17.836 4.994 34.651-11.837 29.661-29.671l-17.661-62.015 62.65-15.99c17.987-4.302 24.366-27.367 10.664-40.339l-45.984-45.004z"></path></svg>
|
||||
|
After Width: | Height: | Size: 1.0 KiB |
@@ -0,0 +1 @@
|
||||
<svg aria-hidden="true" focusable="false" data-prefix="fab" data-icon="firefox-browser" class="svg-inline--fa fa-firefox-browser fa-w-16" role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path fill="currentColor" d="M189.37,152.86Zm-58.74-29.37C130.79,123.5,130.71,123.5,130.63,123.49Zm351.42,45.35c-10.61-25.5-32.08-53-48.94-61.73,13.72,26.89,21.67,53.88,24.7,74,0,0,0,.14.05.41-27.58-68.75-74.35-96.47-112.55-156.83-1.93-3.05-3.86-6.11-5.74-9.33-1-1.65-1.86-3.34-2.69-5.05A44.88,44.88,0,0,1,333.24.69a.63.63,0,0,0-.55-.66.9.9,0,0,0-.46,0l-.12.07-.18.1.1-.14c-54.23,31.77-76.72,87.38-82.5,122.78a130,130,0,0,0-48.33,12.33,6.25,6.25,0,0,0-3.09,7.75,6.13,6.13,0,0,0,7.79,3.79l.52-.21a117.84,117.84,0,0,1,42.11-11l1.42-.1c2-.12,4-.2,6-.22A122.61,122.61,0,0,1,291,140c.67.2,1.32.42,2,.63,1.89.57,3.76,1.2,5.62,1.87,1.36.5,2.71,1,4.05,1.58,1.09.44,2.18.88,3.25,1.35q2.52,1.13,5,2.35c.75.37,1.5.74,2.25,1.13q2.4,1.26,4.74,2.63,1.51.87,3,1.8a124.89,124.89,0,0,1,42.66,44.13c-13-9.15-36.35-18.19-58.82-14.28,87.74,43.86,64.18,194.9-57.39,189.2a108.43,108.43,0,0,1-31.74-6.12c-2.42-.91-4.8-1.89-7.16-2.93-1.38-.63-2.76-1.27-4.12-2C174.5,346,149.9,316.92,146.83,281.59c0,0,11.25-41.95,80.62-41.95,7.5,0,28.93-20.92,29.33-27-.09-2-42.54-18.87-59.09-35.18-8.85-8.71-13.05-12.91-16.77-16.06a69.58,69.58,0,0,0-6.31-4.77A113.05,113.05,0,0,1,173.92,97c-25.06,11.41-44.55,29.45-58.71,45.37h-.12c-9.67-12.25-9-52.65-8.43-61.08-.12-.53-7.22,3.68-8.15,4.31a178.54,178.54,0,0,0-23.84,20.43A214,214,0,0,0,51.9,133.36l0,0a.08.08,0,0,1,0,0,205.84,205.84,0,0,0-32.73,73.9c-.06.27-2.33,10.21-4,22.48q-.42,2.87-.78,5.74c-.57,3.69-1,7.71-1.44,14,0,.24,0,.48-.05.72-.18,2.71-.34,5.41-.49,8.12,0,.41,0,.82,0,1.24,0,134.7,109.21,243.89,243.92,243.89,120.64,0,220.82-87.58,240.43-202.62.41-3.12.74-6.26,1.11-9.41,4.85-41.83-.54-85.79-15.82-122.55Z"></path></svg>
|
||||
|
After Width: | Height: | Size: 1.8 KiB |
@@ -0,0 +1 @@
|
||||
<svg aria-hidden="true" focusable="false" data-prefix="fab" data-icon="linux" class="svg-inline--fa fa-linux fa-w-14" role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512"><path fill="currentColor" d="M220.8 123.3c1 .5 1.8 1.7 3 1.7 1.1 0 2.8-.4 2.9-1.5.2-1.4-1.9-2.3-3.2-2.9-1.7-.7-3.9-1-5.5-.1-.4.2-.8.7-.6 1.1.3 1.3 2.3 1.1 3.4 1.7zm-21.9 1.7c1.2 0 2-1.2 3-1.7 1.1-.6 3.1-.4 3.5-1.6.2-.4-.2-.9-.6-1.1-1.6-.9-3.8-.6-5.5.1-1.3.6-3.4 1.5-3.2 2.9.1 1 1.8 1.5 2.8 1.4zM420 403.8c-3.6-4-5.3-11.6-7.2-19.7-1.8-8.1-3.9-16.8-10.5-22.4-1.3-1.1-2.6-2.1-4-2.9-1.3-.8-2.7-1.5-4.1-2 9.2-27.3 5.6-54.5-3.7-79.1-11.4-30.1-31.3-56.4-46.5-74.4-17.1-21.5-33.7-41.9-33.4-72C311.1 85.4 315.7.1 234.8 0 132.4-.2 158 103.4 156.9 135.2c-1.7 23.4-6.4 41.8-22.5 64.7-18.9 22.5-45.5 58.8-58.1 96.7-6 17.9-8.8 36.1-6.2 53.3-6.5 5.8-11.4 14.7-16.6 20.2-4.2 4.3-10.3 5.9-17 8.3s-14 6-18.5 14.5c-2.1 3.9-2.8 8.1-2.8 12.4 0 3.9.6 7.9 1.2 11.8 1.2 8.1 2.5 15.7.8 20.8-5.2 14.4-5.9 24.4-2.2 31.7 3.8 7.3 11.4 10.5 20.1 12.3 17.3 3.6 40.8 2.7 59.3 12.5 19.8 10.4 39.9 14.1 55.9 10.4 11.6-2.6 21.1-9.6 25.9-20.2 12.5-.1 26.3-5.4 48.3-6.6 14.9-1.2 33.6 5.3 55.1 4.1.6 2.3 1.4 4.6 2.5 6.7v.1c8.3 16.7 23.8 24.3 40.3 23 16.6-1.3 34.1-11 48.3-27.9 13.6-16.4 36-23.2 50.9-32.2 7.4-4.5 13.4-10.1 13.9-18.3.4-8.2-4.4-17.3-15.5-29.7zM223.7 87.3c9.8-22.2 34.2-21.8 44-.4 6.5 14.2 3.6 30.9-4.3 40.4-1.6-.8-5.9-2.6-12.6-4.9 1.1-1.2 3.1-2.7 3.9-4.6 4.8-11.8-.2-27-9.1-27.3-7.3-.5-13.9 10.8-11.8 23-4.1-2-9.4-3.5-13-4.4-1-6.9-.3-14.6 2.9-21.8zM183 75.8c10.1 0 20.8 14.2 19.1 33.5-3.5 1-7.1 2.5-10.2 4.6 1.2-8.9-3.3-20.1-9.6-19.6-8.4.7-9.8 21.2-1.8 28.1 1 .8 1.9-.2-5.9 5.5-15.6-14.6-10.5-52.1 8.4-52.1zm-13.6 60.7c6.2-4.6 13.6-10 14.1-10.5 4.7-4.4 13.5-14.2 27.9-14.2 7.1 0 15.6 2.3 25.9 8.9 6.3 4.1 11.3 4.4 22.6 9.3 8.4 3.5 13.7 9.7 10.5 18.2-2.6 7.1-11 14.4-22.7 18.1-11.1 3.6-19.8 16-38.2 14.9-3.9-.2-7-1-9.6-2.1-8-3.5-12.2-10.4-20-15-8.6-4.8-13.2-10.4-14.7-15.3-1.4-4.9 0-9 4.2-12.3zm3.3 334c-2.7 35.1-43.9 34.4-75.3 18-29.9-15.8-68.6-6.5-76.5-21.9-2.4-4.7-2.4-12.7 2.6-26.4v-.2c2.4-7.6.6-16-.6-23.9-1.2-7.8-1.8-15 .9-20 3.5-6.7 8.5-9.1 14.8-11.3 10.3-3.7 11.8-3.4 19.6-9.9 5.5-5.7 9.5-12.9 14.3-18 5.1-5.5 10-8.1 17.7-6.9 8.1 1.2 15.1 6.8 21.9 16l19.6 35.6c9.5 19.9 43.1 48.4 41 68.9zm-1.4-25.9c-4.1-6.6-9.6-13.6-14.4-19.6 7.1 0 14.2-2.2 16.7-8.9 2.3-6.2 0-14.9-7.4-24.9-13.5-18.2-38.3-32.5-38.3-32.5-13.5-8.4-21.1-18.7-24.6-29.9s-3-23.3-.3-35.2c5.2-22.9 18.6-45.2 27.2-59.2 2.3-1.7.8 3.2-8.7 20.8-8.5 16.1-24.4 53.3-2.6 82.4.6-20.7 5.5-41.8 13.8-61.5 12-27.4 37.3-74.9 39.3-112.7 1.1.8 4.6 3.2 6.2 4.1 4.6 2.7 8.1 6.7 12.6 10.3 12.4 10 28.5 9.2 42.4 1.2 6.2-3.5 11.2-7.5 15.9-9 9.9-3.1 17.8-8.6 22.3-15 7.7 30.4 25.7 74.3 37.2 95.7 6.1 11.4 18.3 35.5 23.6 64.6 3.3-.1 7 .4 10.9 1.4 13.8-35.7-11.7-74.2-23.3-84.9-4.7-4.6-4.9-6.6-2.6-6.5 12.6 11.2 29.2 33.7 35.2 59 2.8 11.6 3.3 23.7.4 35.7 16.4 6.8 35.9 17.9 30.7 34.8-2.2-.1-3.2 0-4.2 0 3.2-10.1-3.9-17.6-22.8-26.1-19.6-8.6-36-8.6-38.3 12.5-12.1 4.2-18.3 14.7-21.4 27.3-2.8 11.2-3.6 24.7-4.4 39.9-.5 7.7-3.6 18-6.8 29-32.1 22.9-76.7 32.9-114.3 7.2zm257.4-11.5c-.9 16.8-41.2 19.9-63.2 46.5-13.2 15.7-29.4 24.4-43.6 25.5s-26.5-4.8-33.7-19.3c-4.7-11.1-2.4-23.1 1.1-36.3 3.7-14.2 9.2-28.8 9.9-40.6.8-15.2 1.7-28.5 4.2-38.7 2.6-10.3 6.6-17.2 13.7-21.1.3-.2.7-.3 1-.5.8 13.2 7.3 26.6 18.8 29.5 12.6 3.3 30.7-7.5 38.4-16.3 9-.3 15.7-.9 22.6 5.1 9.9 8.5 7.1 30.3 17.1 41.6 10.6 11.6 14 19.5 13.7 24.6zM173.3 148.7c2 1.9 4.7 4.5 8 7.1 6.6 5.2 15.8 10.6 27.3 10.6 11.6 0 22.5-5.9 31.8-10.8 4.9-2.6 10.9-7 14.8-10.4s5.9-6.3 3.1-6.6-2.6 2.6-6 5.1c-4.4 3.2-9.7 7.4-13.9 9.8-7.4 4.2-19.5 10.2-29.9 10.2s-18.7-4.8-24.9-9.7c-3.1-2.5-5.7-5-7.7-6.9-1.5-1.4-1.9-4.6-4.3-4.9-1.4-.1-1.8 3.7 1.7 6.5z"></path></svg>
|
||||
|
After Width: | Height: | Size: 3.6 KiB |
@@ -0,0 +1 @@
|
||||
<svg aria-hidden="true" focusable="false" data-prefix="fab" data-icon="windows" class="svg-inline--fa fa-windows fa-w-14" role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512"><path fill="currentColor" d="M0 93.7l183.6-25.3v177.4H0V93.7zm0 324.6l183.6 25.3V268.4H0v149.9zm203.8 28L448 480V268.4H203.8v177.9zm0-380.6v180.1H448V32L203.8 65.7z"></path></svg>
|
||||
|
After Width: | Height: | Size: 369 B |
@@ -0,0 +1,143 @@
|
||||
{% extends "layout.html" %}
|
||||
{% block content %}
|
||||
<div class="row justify-content-md-center">
|
||||
<div class="col-md-9">
|
||||
<!--suppress HtmlUnknownTag -->
|
||||
<h3 class="my-4">Install mitmproxy's Certificate Authority</h3>
|
||||
|
||||
{% macro entry(title, icon, filetype="pem") -%}
|
||||
<li class="media">
|
||||
{% include 'icons/' + icon + '-brands.svg' %}
|
||||
<div class="media-body">
|
||||
<h5 class="mt-0">{{ title | safe }}</h5>
|
||||
<a class="btn btn-sm btn-success" href="/cert/{{ filetype }}" target="_blank">🔏 Get mitmproxy-ca-cert.{{
|
||||
filetype }}</a>
|
||||
<a class="btn btn-sm btn-info show-instructions" href="#{{ title.split(' ')[0] }}" id="{{ title.split(' ')[0] }}">📖
|
||||
Show Instructions</a>
|
||||
<a class="btn btn-sm btn-info hide-instructions" href="#/">📖 Hide Instructions</a>
|
||||
<div class="instructions">{{ caller() }}</div>
|
||||
</div>
|
||||
</li>
|
||||
{%- endmacro %}
|
||||
|
||||
<ul class="list-unstyled">
|
||||
{% call entry('Windows', 'windows', 'p12') %}
|
||||
<h5>Manual Installation</h5>
|
||||
<ol>
|
||||
<li>Double-click the P12 file to start the import wizard.</li>
|
||||
<li>Select a certificate store location. This determines who will trust the certificate – only the current
|
||||
Windows user or everyone on the machine. Click <samp>Next</samp>.
|
||||
</li>
|
||||
<li>Click <samp>Next</samp> again.</li>
|
||||
<li>Leave <samp>Password</samp> blank and click <samp>Next</samp>.</li>
|
||||
<li><span class="text-danger">Select <samp>Place all certificates in the following store</samp></span>,
|
||||
then click <samp>Browse</samp>, and select <samp>Trusted Root Certification Authorities</samp>.<br>
|
||||
Click <samp>OK</samp> and <samp>Next</samp>.
|
||||
</li>
|
||||
<li>Click <samp>Finish</samp>.</li>
|
||||
<li>Click <samp>Yes</samp> to confirm the warning dialog.</li>
|
||||
</ol>
|
||||
<h5>Automated Installation</h5>
|
||||
<ol>
|
||||
<li>Run <code>certutil.exe -addstore root mitmproxy-ca-cert.cer</code>
|
||||
(<a href="https://technet.microsoft.com/en-us/library/cc732443.aspx">details</a>).
|
||||
</li>
|
||||
</ol>
|
||||
{% endcall %}
|
||||
{% call entry('Linux', 'linux') %}
|
||||
<h5>Ubuntu/Debian</h5>
|
||||
<ol>
|
||||
<li><code>mv mitmproxy-ca-cert.pem /usr/local/share/ca-certificates/mitmproxy.crt</code></li>
|
||||
<li><code>sudo update-ca-certificates</code></li>
|
||||
</ol>
|
||||
<h5>Fedora</h5>
|
||||
<ol>
|
||||
<li><code>mv mitmproxy-ca-cert.pem /etc/pki/ca-trust/source/anchors/</code></li>
|
||||
<li><code>sudo update-ca-trust</code></li>
|
||||
</ol>
|
||||
<h5>Arch Linux</h5>
|
||||
<ol>
|
||||
<code>sudo trust anchor --store mitmproxy-ca-cert.pem</code>
|
||||
</ol>
|
||||
{% endcall %}
|
||||
{% call entry('macOS', 'apple') %}
|
||||
<h5>Manual Installation</h5>
|
||||
<ol>
|
||||
<li>Double-click the PEM file to open the <samp>Keychain Access</samp> application.</li>
|
||||
<li>Locate the new certificate "mitmproxy" in the list and double-click it.</li>
|
||||
<li>Change <samp>Secure Socket Layer (SSL)</samp> to <samp>Always Trust</samp>.</li>
|
||||
<li>Close the dialog window and enter your password if prompted.</li>
|
||||
</ol>
|
||||
<h5>Automated Installation</h5>
|
||||
<ol>
|
||||
<li><code>sudo security add-trusted-cert -d -p ssl -p basic -k /Library/Keychains/System.keychain mitmproxy-ca-cert.pem</code></li>
|
||||
</ol>
|
||||
{% endcall %}
|
||||
{% call entry('iOS <small>– please read the instructions!</small>', 'apple') %}
|
||||
<h5>iOS 13+</h5>
|
||||
<ol>
|
||||
<li>Use Safari to download the certificate. Other browsers may not open the proper installation prompt.</li>
|
||||
<li>Install the new Profile (<samp>Settings -> General -> VPN & Device Management</samp>).</li>
|
||||
<li><span class="text-danger"><strong>Important:</strong> Go to <samp>Settings -> General -> About -> Certificate Trust Settings</samp>.
|
||||
Toggle <samp>mitmproxy</samp> to <samp>ON</samp>.</span></li>
|
||||
</ol>
|
||||
{% endcall %}
|
||||
{% call entry('Android', 'android', 'cer') %}
|
||||
<h5>Android 10+</h5>
|
||||
<ol class="mb-2">
|
||||
<li>Open the downloaded CER file.</li>
|
||||
<li>Enter <samp>mitmproxy</samp> (or anything else) as the certificate name.</li>
|
||||
<li>For credential use, select <samp>VPN and apps</samp>.</li>
|
||||
<li>Click OK.</li>
|
||||
</ol>
|
||||
|
||||
<p>Some Android distributions require you to install the certificate via <samp>Settings -> Security -> Advanced ->
|
||||
Encryption and credentials -> Install a certificate -> CA certificate</samp> (or similar) instead.</p>
|
||||
|
||||
<div class="alert alert-warning" role="alert">
|
||||
<p><strong>Warning: </strong>Apps that target Android API Level 24 (introduced in 2016) and above only accept
|
||||
certificates from the system trust store
|
||||
(<a href="https://github.com/mitmproxy/mitmproxy/issues/2054">#2054</a>).
|
||||
User-added CAs are not accepted unless the application manually opts in. Except for browsers, you need to
|
||||
patch most apps manually
|
||||
(<a href="https://developer.android.com/training/articles/security-config">Android network security config</a>).
|
||||
</p>
|
||||
<p>
|
||||
Alternatively, if you have rooted the device and have Magisk installed, you can install <a href="/cert/magisk">this Magisk module</a> via the Magisk Manager app.
|
||||
</p>
|
||||
</div>
|
||||
{% endcall %}
|
||||
{% call entry('Firefox <small>(does not use the OS root certificates)</small>', 'firefox-browser') %}
|
||||
<h5>Firefox</h5>
|
||||
<ol>
|
||||
<li>Open <samp>Options -> Privacy & Security</samp> and click <samp>View Certificates...</samp>
|
||||
at the bottom of the page.</li>
|
||||
<li>Click <samp>Import...</samp> and select the downloaded certificate.</li>
|
||||
<li>Enable <samp>Trust this CA to identify websites</samp> and click <samp>OK</samp>.</li>
|
||||
</ol>
|
||||
{% endcall %}
|
||||
<li class="media">
|
||||
{% include 'icons/certificate-solid.svg' %}
|
||||
<div class="media-body">
|
||||
<h5 class="mt-0">Other Platforms</h5>
|
||||
<a class="btn btn-sm btn-success" href="/cert/pem" target="_blank">🔏 Get mitmproxy-ca-cert.pem</a>
|
||||
<a class="btn btn-sm btn-success" href="/cert/p12" target="_blank">🔏 Get mitmproxy-ca-cert.p12</a>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<hr/>
|
||||
|
||||
<p>
|
||||
Other mitmproxy users cannot intercept your connection.
|
||||
<span class="text-muted">
|
||||
This page is served by your local mitmproxy instance. The certificate you are about to install has been uniquely
|
||||
generated on mitmproxy's first run and is not shared
|
||||
between mitmproxy installations.
|
||||
</span>
|
||||
</p>
|
||||
|
||||
|
||||
{% endblock %}
|
||||
@@ -0,0 +1,29 @@
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||
|
||||
<title>mitmproxy</title>
|
||||
<link href="static/bootstrap.min.css" rel="stylesheet">
|
||||
<link href="static/mitmproxy.css" rel="stylesheet">
|
||||
<link rel="icon" href="static/images/favicon.ico" type="image/x-icon"/>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<nav class="navbar navbar-dark bg-dark mb-3">
|
||||
<div class="container">
|
||||
<div class="navbar-header">
|
||||
<div class="navbar-brand">
|
||||
<img src="static/images/mitmproxy-long.png" height="30" alt="mitmproxy logo" class="align-top"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
<div class="container">
|
||||
{% block content %}
|
||||
{% endblock %}
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||