generated from security-union/yew-actix-template
-
Notifications
You must be signed in to change notification settings - Fork 127
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3166e1a
commit c12d61d
Showing
2 changed files
with
37 additions
and
7 deletions.
There are no files selected for viewing
This file contains 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 contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
|
||
SCRIPTPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" | ||
|
||
# generate certificate | ||
|
||
#openssl req -x509 -newkey rsa:2048 -keyout $SCRIPTPATH/certs/localhost.key -out $SCRIPTPATH/certs/localhost.pem -days 365 -nodes -subj "/CN=127.0.0.1" | ||
|
||
#openssl x509 -in $SCRIPTPATH/certs/localhost.pem -outform der -out $SCRIPTPATH/certs/localhost.der | ||
|
||
#openssl rsa -in $SCRIPTPATH/certs/localhost.key -outform DER -out $SCRIPTPATH/certs/localhost_key.der | ||
|
||
SPKI=`openssl x509 -inform der -in $SCRIPTPATH/actix-api/certs/localhost.der -pubkey -noout | openssl pkey -pubin -outform der | openssl dgst -sha256 -binary | openssl enc -base64` | ||
|
||
echo "Got cert key $SPKI" | ||
|
||
echo "Opening google chrome" | ||
|
||
case `uname` in | ||
(*Linux*) google-chrome --origin-to-force-quic-on=127.0.0.1:4433 --ignore-certificate-errors-spki-list=$SPKI --enable-logging --v=1 ;; | ||
(*Darwin*) open -a "Google Chrome" --args --origin-to-force-quic-on=127.0.0.1:4433 --ignore-certificate-errors-spki-list=$SPKI --enable-logging --v=1 ;; | ||
esac | ||
|
||
## Logs are stored to ~/Library/Application Support/Google/Chrome/chrome_debug.log |