summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon MacMullen <simon@rabbitmq.com>2010-11-10 11:11:27 +0000
committerSimon MacMullen <simon@rabbitmq.com>2010-11-10 11:11:27 +0000
commit319e4fd140980f20f92a7b25af8f025f3d4905a2 (patch)
treea8891ac04cf3aaa11f7dbb0fd2cf7b6d9c1adf52
parent0fedfadb32ab77f8affe534b9c3ca2caf2787d1d (diff)
downloadrabbitmq-server-319e4fd140980f20f92a7b25af8f025f3d4905a2.tar.gz
Add auth_mechanism info key
-rw-r--r--src/rabbit_reader.erl6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/rabbit_reader.erl b/src/rabbit_reader.erl
index 907a00a8..ceaf9fd2 100644
--- a/src/rabbit_reader.erl
+++ b/src/rabbit_reader.erl
@@ -68,7 +68,7 @@
-define(CREATION_EVENT_KEYS, [pid, address, port, peer_address, peer_port,
peer_cert_subject, peer_cert_issuer,
- peer_cert_validity,
+ peer_cert_validity, auth_mechanism,
protocol, user, vhost, timeout, frame_max,
client_properties]).
@@ -907,6 +907,10 @@ i(protocol, #v1{connection = #connection{protocol = none}}) ->
none;
i(protocol, #v1{connection = #connection{protocol = Protocol}}) ->
Protocol:version();
+i(auth_mechanism, #v1{auth_mechanism = none}) ->
+ none;
+i(auth_mechanism, #v1{auth_mechanism = Mechanism}) ->
+ proplists:get_value(name, Mechanism:description());
i(user, #v1{connection = #connection{user = #user{username = Username}}}) ->
Username;
i(user, #v1{connection = #connection{user = none}}) ->