diff options
author | Michael Steinert <mike.steinert@gmail.com> | 2012-08-30 16:08:23 -0600 |
---|---|---|
committer | Alan Antonuk <alan.antonuk@gmail.com> | 2013-04-09 15:53:03 -0700 |
commit | 09eccb1c0832713f377235c941716007085b47fc (patch) | |
tree | bd2124d29547fb740e5b7d6e51870f1a57d43788 /examples/amqps_unbind.c | |
parent | 15a80404bec02e6fbf47108f306f6b3020bc078d (diff) | |
download | rabbitmq-c-09eccb1c0832713f377235c941716007085b47fc.tar.gz |
Add API to load SSL keys from a buffer
Signed-off-by: Michael Steinert <mike.steinert@gmail.com>
Diffstat (limited to 'examples/amqps_unbind.c')
-rw-r--r-- | examples/amqps_unbind.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/examples/amqps_unbind.c b/examples/amqps_unbind.c index e9f4317..5c8a4b5 100644 --- a/examples/amqps_unbind.c +++ b/examples/amqps_unbind.c @@ -75,10 +75,17 @@ int main(int argc, char const * const *argv) { } } + if (argc > 7) { + status = amqp_ssl_socket_set_key(socket, argv[7]); + if (status) { + die("setting client key"); + } + } + if (argc > 8) { - status = amqp_ssl_socket_set_key(socket, argv[7], argv[8]); + status = amqp_ssl_socket_set_cert(socket, argv[8]); if (status) { - die("setting client key/cert"); + die("setting client cert"); } } |