/
githubmirror
/
clevis
Обзор
Документация
Войти
/
githubmirror
/
clevis
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
v1
test-pin-http
28 строк
402 B
Nathaniel McCallum
Consolodate source files
01 ноя 2016, 22:42
01 ноя 2016, 22:42
5411087
Код
Авторство
О чём код?
#!/bin/sh -x trap 'exit' ERR PORT=`shuf -i 1024-65535 -n 1` ./test-pin-httpd $PORT & export PID=$! sleep 0.25 function onerr() { kill -9 $PID ! wait $PID exit 1 } trap 'onerr' ERR e=`echo hi | ./clevis-encrypt http "{\"url\": \"http://localhost:${PORT}/foo\"}"` d=`echo $e | ./clevis-decrypt` test "$d" == "hi" kill -9 $PID ! wait $PID trap 'exit' ERR ! echo $e | ./clevis-decrypt