From: Daniel P. Berrangé Date: Tue, 11 Dec 2018 14:58:43 +0000 (+0000) Subject: tools: rename S_ORG to C_ORG in virt-pki-validate X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=34eca98522c1bd39e18f1eceee4f888dad173e5e;p=libvirt.git tools: rename S_ORG to C_ORG in virt-pki-validate Rename a variable to make it clear that it holds the client organization rather than the server organization. Signed-off-by: Daniel P. Berrangé --- diff --git a/tools/virt-pki-validate.in b/tools/virt-pki-validate.in index c3fadbba64..2f7404bd94 100755 --- a/tools/virt-pki-validate.in +++ b/tools/virt-pki-validate.in @@ -201,12 +201,12 @@ then echo Client certificate $LIBVIRT/clientcert.pem should be world readable echo "as root do: chown root:root $LIBVIRT/clientcert.pem ; chmod 644 $LIBVIRT/clientcert.pem" else - S_ORG=`"$CERTOOL" -i --infile "$LIBVIRT/clientcert.pem" | grep Subject: | sed 's+.*O=\([^,]*\).*+\1+'` - if [ "$ORG" != "$S_ORG" ] + C_ORG=`"$CERTOOL" -i --infile "$LIBVIRT/clientcert.pem" | grep Subject: | sed 's+.*O=\([^,]*\).*+\1+'` + if [ "$ORG" != "$C_ORG" ] then echo The CA certificate and the client certificate do not match echo CA organization: $ORG - echo Client organization: $S_ORG + echo Client organization: $C_ORG fi CLIENT=`"$CERTOOL" -i --infile "$LIBVIRT/clientcert.pem" | grep Subject: | sed 's+.*CN=\(.[^,]*\).*+\1+'` echo Found client certificate $LIBVIRT/clientcert.pem for $CLIENT