-
After installing mitmproxy run it (just type
mitmproxy) in a terminal session and quit. This will create the necessaries certificates files at~/.mitmproxy. -
Extract the certificate to
.crtformat:
openssl x509 -in ~/.mitmproxy/mitmproxy-ca.pem -inform PEM -out ca.crt -
Trust the certificate into CA:
sudo trust anchor ca.crt -
Run the
mitmproxyagain
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
| sudo nscd -K |
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
| package main | |
| import ( | |
| "encoding/json" | |
| "fmt" | |
| "io/ioutil" | |
| "net/http" | |
| "os" | |
| "strings" | |
| ) |
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
| const sleep = require('util').promisify(setTimeout); | |
| //... | |
| await sleep(15); | |
| //... |
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
| [Unit] | |
| Description=aws-rotate-key service | |
| After=network-online.target | |
| Wants=network-online.target | |
| [Service] | |
| Type=oneshot | |
| # Wait for connection during 10 seconds before giving up | |
| ExecStart=/usr/bin/sh -c 'let try=1; until nc -z sts.amazonaws.com 443; do sleep 1; let "try+=1"; if [ $try -gt 10 ]; then exit 1; fi; done; /usr/local/bin/aws-rotate-key -profile ${AWS_PROFILE} -y' |
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
| yaourt -S --noconfirm reflector-timer | |
| sudo sh -c 'curl -s https://gist.githubusercontent.com/franciscocpg/98c405cc1867c050e7f12df052d9ec5a/raw/reflector.conf > /etc/conf.d/reflector.conf' | |
| sudo systemctl enable --now reflector.timer |
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
| # This file is autogenerated, do not edit; changes may be undone by the next 'dep ensure'. | |
| [[projects]] | |
| name = "github.com/apex/log" | |
| packages = [ | |
| ".", | |
| "handlers/memory", | |
| "handlers/text" | |
| ] |
To change the pinentry permanently, append the following to your ~/.gnupg/gpg-agent.conf:
pinentry-program /usr/bin/pinentry-tty
Then kill agent: pkill gpg-agent