mirror of
https://github.com/openwrt/packages.git
synced 2025-02-07 09:19:51 +00:00
This also adds a CPE ID for the package and updates the test.sh script to use an assert. Signed-off-by: Jeffery To <jeffery.to@gmail.com>
15 lines
245 B
Bash
15 lines
245 B
Bash
#!/bin/sh
|
|
|
|
[ "$1" = python3-cryptography ] || exit 0
|
|
|
|
python3 - << 'EOF'
|
|
|
|
from cryptography.fernet import Fernet
|
|
key = Fernet.generate_key()
|
|
f = Fernet(key)
|
|
msg = b"my deep dark secret"
|
|
token = f.encrypt(msg)
|
|
assert f.decrypt(token) == msg
|
|
|
|
EOF
|