diff options
| author | Endi S. Dewata <edewata@redhat.com> | 2016-06-09 08:17:14 +0200 |
|---|---|---|
| committer | Endi S. Dewata <edewata@redhat.com> | 2016-06-09 08:17:14 +0200 |
| commit | b48b8e1bcecd9c49558ccc825de85613a9ba4ddd (patch) | |
| tree | f5e35aad9f5abb52dbd2fbdd53f7f6da6dbb371a /scripts/tps-admin-setup.sh | |
| parent | 15b6f9859a2906024f27090ea35ca1991af996f6 (diff) | |
| download | pki-dev-b48b8e1bcecd9c49558ccc825de85613a9ba4ddd.tar.gz pki-dev-b48b8e1bcecd9c49558ccc825de85613a9ba4ddd.tar.xz pki-dev-b48b8e1bcecd9c49558ccc825de85613a9ba4ddd.zip | |
Updated TPS scripts.
Diffstat (limited to 'scripts/tps-admin-setup.sh')
| -rwxr-xr-x | scripts/tps-admin-setup.sh | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/scripts/tps-admin-setup.sh b/scripts/tps-admin-setup.sh new file mode 100755 index 0000000..daacecd --- /dev/null +++ b/scripts/tps-admin-setup.sh @@ -0,0 +1,15 @@ +#!/bin/sh -x + +#pki -d ~/.dogtag/pki-tomcat/ca/alias -c Secret123 -n caadmin tps-user-add tpsadmin --fullName "TPS Administrator" +#pki -d ~/.dogtag/pki-tomcat/ca/alias -c Secret123 -n caadmin tps-group-member-add "Administrators" tpsadmin + +REQUEST_ID=`pki -c Secret123 client-cert-request uid=tpsadmin | grep "Request ID:" | awk -F ': ' '{print $2;}'` +echo Request ID: $REQUEST_ID + +CERT_ID=`pki -d ~/.dogtag/pki-tomcat/ca/alias -c Secret123 -n caadmin ca-cert-request-review --action approve $REQUEST_ID | grep "Certificate ID:" | awk -F ': ' '{print $2;}'` +echo Certificate ID: $CERT_ID + +pki -d ~/.dogtag/pki-tomcat/ca/alias -c Secret123 -n caadmin tps-user-cert-add tpsadmin --serial $CERT_ID +pki -c Secret123 client-cert-import tpsadmin --serial $CERT_ID + +pki -c Secret123 client-cert-show tpsadmin --pkcs12 tpsadmin.p12 --pkcs12-password Secret123 |
