Skip to content

Commit 1fefa5d

Browse files
committed
add tmp github action
1 parent 2d1d745 commit 1fefa5d

File tree

1 file changed

+29
-0
lines changed

1 file changed

+29
-0
lines changed

.github/workflows/tmp.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Recovering secrets
2+
3+
# Assumption:
4+
# You've created the following GitHub secrets in your repository:
5+
# MY_CLIENT_SECRET - encrypt/decrypt with openssl - useful for public and public repositories
6+
# MY_OPENSSL_PASSWORD - used to protect secrets
7+
# MY_OPENSSL_ITER - Use a number of iterations on the password to derive the encryption key.
8+
# High values increase the time required to brute-force the resulting file.
9+
# This option enables the use of PBKDF2 algorithm to derive the key.
10+
11+
on:
12+
push:
13+
workflow_dispatch:
14+
15+
jobs:
16+
openssl:
17+
name: Recover With OpenSSL
18+
runs-on: ubuntu-20.04
19+
steps:
20+
- uses: actions/checkout@v3
21+
- env:
22+
#KEY_ALIAS: ${{ secrets.KEY_ALIAS }}
23+
#KEY_PASSWORD: ${{ secrets.KEY_PASSWORD }}
24+
#KEY_STORE: ${{ secrets.KEY_STORE }}
25+
KEY_STORE_PASSWORD: ${{ secrets.KEY_STORE_PASSWORD }}
26+
OPENSSL_PASSWORD: ${{ secrets.OPENSSL_PASSWORD }}
27+
OPENSSL_ITER: ${{ secrets.OPENSSL_ITER }}
28+
run: |
29+
echo "$(echo "${KEY_STORE_PASSWORD}" | openssl enc -e -aes-256-cbc -a -pbkdf2 -iter ${OPENSSL_ITER} -k "${OPENSSL_PASSWORD}" | perl -lpe '$_=unpack"B*"')"

0 commit comments

Comments
 (0)