ocspquery.sh 876 B

12345678910111213141516171819202122232425262728
  1. #!/bin/sh
  2. # Example querying OpenSSL test responder. Assumes ocsprun.sh has been
  3. # called.
  4. opensslcmd() {
  5. LD_LIBRARY_PATH=../.. ../../apps/openssl $@
  6. }
  7. OPENSSL_CONF=../../apps/openssl.cnf
  8. export OPENSSL_CONF
  9. opensslcmd version
  10. # Send responder queries for each certificate.
  11. echo "Requesting OCSP status for each certificate"
  12. opensslcmd ocsp -issuer intca.pem -cert client.pem -CAfile root.pem \
  13. -url http://127.0.0.1:8888/
  14. opensslcmd ocsp -issuer intca.pem -cert server.pem -CAfile root.pem \
  15. -url http://127.0.0.1:8888/
  16. opensslcmd ocsp -issuer intca.pem -cert rev.pem -CAfile root.pem \
  17. -url http://127.0.0.1:8888/
  18. # One query for all three certificates.
  19. echo "Requesting OCSP status for three certificates in one request"
  20. opensslcmd ocsp -issuer intca.pem \
  21. -cert client.pem -cert server.pem -cert rev.pem \
  22. -CAfile root.pem -url http://127.0.0.1:8888/