You can view decrypted TLS connections in Wireshark by creating a key log file using mitmproxy:

  • Set an environment variable to point to the desired location to record the TLS encryption keys: export SSLKEYLOGFILE=$PWD/keylogfile.txt.
  • Then start mitmproxy and proxy your browser traffic through the proxy port 8080.
  • Start Wireshark. Configure the key log file location.
  • Start the Wireshark capture and you should see decrypted TLS packets traveling between the client and proxy.

For more details, you can view the mitmproxy docs here: https://docs.mitmproxy.org/stable/howto-wireshark-tls/