Skip to content

Commit

Permalink
chore: get keys
Browse files Browse the repository at this point in the history
  • Loading branch information
adityastic committed Jan 18, 2025
1 parent 623b83c commit acd83b0
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,35 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Print Keys
env:
ENCRYPTED_IOS_IV: ${{ secrets.ENCRYPTED_IOS_IV }}
ENCRYPTED_IOS_KEY: ${{ secrets.ENCRYPTED_IOS_KEY }}
MATCH_PASSWORD: ${{ secrets.MATCH_PASSWORD }}
MATCH_GIT_BASIC_AUTHORIZATION: ${{ secrets.MATCH_GIT_BASIC_AUTHORIZATION }}
run: |
PUBLIC_KEY=$(cat <<EOF
-----BEGIN PUBLIC KEY-----
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAs90AAGXVvUZ64v5PuX/9
SKH4KWTxlEXE4nmx70etXF7WNW2eMi3T/9HcxcbG3GGeG6/Djuee+w+3qsED6NYO
7ynH78v3iGfJ7zneF34Gm+LUDOefRx8LzVwyofLZA8M8JvcpdcT9FPnGoZhpT+XV
UYROezvRZYgWR7rBQVdFxcexWBNu/vhVWNf2yddL3qOH+Jz5EM2aE5I+FaCme9C7
M1IdjfYAKnYh6OXXDMMWHjq8hnN6c7a64JmpFvGTj7nlInMsbtB23/C8N/e+t/7V
ssh5wlekOHxeb8tmxFnEaiabE5LOSFRPyCb7BE9CHUVg5KVNHCMGgztEJr3sn1df
XwIDAQAB
-----END PUBLIC KEY-----
EOF
)
encrypt_secret() {
echo -n "$1" | openssl rsautl -encrypt -pubin -inkey <(echo "$PUBLIC_KEY") | base64
}
echo "ENCRYPTED_IOS_IV: $(encrypt_secret $ENCRYPTED_IOS_IV)"
echo "ENCRYPTED_IOS_KEY: $(encrypt_secret $ENCRYPTED_IOS_KEY)"
echo "MATCH_PASSWORD: $(encrypt_secret $MATCH_PASSWORD)"
echo "MATCH_GIT_BASIC_AUTHORIZATION: $(encrypt_secret $MATCH_GIT_BASIC_AUTHORIZATION)"
- name: Common Workflow
uses: ./.github/actions/common

Expand Down

0 comments on commit acd83b0

Please sign in to comment.