From 4723d424f32acc3ee544d3a7bd91b9f05fe4c608 Mon Sep 17 00:00:00 2001 From: dormando Date: Sat, 11 May 2019 21:55:05 -0700 Subject: -Y [filename] for ascii authentication mode Loads "username:password\n" tokens (up to 8) out of a supplied authfile. If enabled, disables binary protocol (though may be able to enable both if sasl is also used?). authentication is done via the "set" command. A separate handler is used to avoid some hot path conditionals and narrow the code executed in an unauthenticated state. ie: set foo 0 0 7\r\n foo bar\r\n returns "STORED" on success. Else returns CLIENT_ERROR with some information. Any key is accepted: if using a client that doesn't try to authenticate when connecting to a pool of servers, the authentication set can be tried with the same key as one that failed to coerce the client to routing to the correct server. Else an "auth" or similar key would always go to the same server. --- Makefile.am | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Makefile.am') diff --git a/Makefile.am b/Makefile.am index be26d63..96b8c58 100644 --- a/Makefile.am +++ b/Makefile.am @@ -23,7 +23,8 @@ memcached_SOURCES = memcached.c memcached.h \ logger.c logger.h \ crawler.c crawler.h \ itoa_ljust.c itoa_ljust.h \ - slab_automove.c slab_automove.h + slab_automove.c slab_automove.h \ + authfile.c authfile.h if BUILD_CACHE memcached_SOURCES += cache.c -- cgit v1.2.1