Author: mgoulish Date: Mon May 24 18:25:46 2010 New Revision: 947748 URL: http://svn.apache.org/viewvc?rev=947748&view=rev Log: Jira QPID-2617 -- make sasl-based tests config files relocatable
Before this change, sasl-based testing cannot be fully automated because the sasl db must be located in the standard installation location of /etc/sasl2. * Created a new directory "sasl_config" under cpp/src/tests * added a new makefile fragment "sasl.mk" to cpp/src/Makefile.am conditionally included basedon HAVE_SASL, which is defined by configure. ( NOTE: should be in cpp/src/tests/Makefile.am, but getting an "saslpasswd2: generic failure" when I try that. ) * The sasl.mk fragment uses saslpasswd2 to create a sasl db in cpp/src/tests/sasl_config that defines two users with eponymous passwords. * In test cluster_authentication_soak.cpp, make the cluster name random. * make SaslAuthenticator code accept and use a config path * give cluster_authentication_soak self-test capability. the test is meant to detect two problems: - broker failure - perftest hang so give it flags that will force either of those conditions. This allows me to (anually) ensure that the test really does detect those conditions when they occur. Added: qpid/trunk/qpid/cpp/src/sasl.mk qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_soak (with props) qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_test (with props) qpid/trunk/qpid/cpp/src/tests/sasl_config/ qpid/trunk/qpid/cpp/src/tests/sasl_config/qpidd.conf Modified: qpid/trunk/qpid/cpp/src/Makefile.am qpid/trunk/qpid/cpp/src/qpid/broker/Broker.cpp qpid/trunk/qpid/cpp/src/qpid/broker/Broker.h qpid/trunk/qpid/cpp/src/qpid/broker/SaslAuthenticator.cpp qpid/trunk/qpid/cpp/src/qpid/broker/SaslAuthenticator.h qpid/trunk/qpid/cpp/src/tests/ForkedBroker.cpp qpid/trunk/qpid/cpp/src/tests/ForkedBroker.h qpid/trunk/qpid/cpp/src/tests/Makefile.am qpid/trunk/qpid/cpp/src/tests/cluster_authentication_soak.cpp Modified: qpid/trunk/qpid/cpp/src/Makefile.am URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/Makefile.am?rev=947748&r1=947747&r2=947748&view=diff ============================================================================== --- qpid/trunk/qpid/cpp/src/Makefile.am (original) +++ qpid/trunk/qpid/cpp/src/Makefile.am Mon May 24 18:25:46 2010 @@ -268,6 +268,7 @@ if SSL include ssl.mk endif + # New 0-10 codec, to be integrated in future. # libqpidamqp_0_10_la_SOURCES= EXTRA_DIST +=\ @@ -488,6 +489,8 @@ if HAVE_SASL libqpidcommon_la_SOURCES += qpid/sys/cyrus/CyrusSecurityLayer.h libqpidcommon_la_SOURCES += qpid/sys/cyrus/CyrusSecurityLayer.cpp libqpidcommon_la_LIBADD += -lsasl2 + +include sasl.mk endif libqpidbroker_la_LIBADD = libqpidcommon.la -luuid Modified: qpid/trunk/qpid/cpp/src/qpid/broker/Broker.cpp URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/qpid/broker/Broker.cpp?rev=947748&r1=947747&r2=947748&view=diff ============================================================================== --- qpid/trunk/qpid/cpp/src/qpid/broker/Broker.cpp (original) +++ qpid/trunk/qpid/cpp/src/qpid/broker/Broker.cpp Mon May 24 18:25:46 2010 @@ -124,6 +124,7 @@ Broker::Options::Options(const std::stri ("tcp-nodelay", optValue(tcpNoDelay), "Set TCP_NODELAY on TCP connections") ("require-encryption", optValue(requireEncrypted), "Only accept connections that are encrypted") ("known-hosts-url", optValue(knownHosts, "URL or 'none'"), "URL to send as 'known-hosts' to clients ('none' implies empty list)") + ("sasl-config", optValue(saslConfigPath, "FILE"), "gets sasl config from nonstandard location") ("max-session-rate", optValue(maxSessionRate, "MESSAGES/S"), "Sets the maximum message rate per session (0=unlimited)") ("async-queue-events", optValue(asyncQueueEvents, "yes|no"), "Set Queue Events async, used for services like replication"); } @@ -263,7 +264,7 @@ Broker::Broker(const Broker::Options& co * SASL setup, can fail and terminate startup */ if (conf.auth) { - SaslAuthenticator::init(qpid::saslName); + SaslAuthenticator::init(qpid::saslName, conf.saslConfigPath); QPID_LOG(info, "SASL enabled"); } else { QPID_LOG(notice, "SASL disabled: No Authentication Performed"); Modified: qpid/trunk/qpid/cpp/src/qpid/broker/Broker.h URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/qpid/broker/Broker.h?rev=947748&r1=947747&r2=947748&view=diff ============================================================================== --- qpid/trunk/qpid/cpp/src/qpid/broker/Broker.h (original) +++ qpid/trunk/qpid/cpp/src/qpid/broker/Broker.h Mon May 24 18:25:46 2010 @@ -110,6 +110,7 @@ public: bool tcpNoDelay; bool requireEncrypted; std::string knownHosts; + std::string saslConfigPath; uint32_t maxSessionRate; bool asyncQueueEvents; bool qmf2Support; Modified: qpid/trunk/qpid/cpp/src/qpid/broker/SaslAuthenticator.cpp URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/qpid/broker/SaslAuthenticator.cpp?rev=947748&r1=947747&r2=947748&view=diff ============================================================================== --- qpid/trunk/qpid/cpp/src/qpid/broker/SaslAuthenticator.cpp (original) +++ qpid/trunk/qpid/cpp/src/qpid/broker/SaslAuthenticator.cpp Mon May 24 18:25:46 2010 @@ -93,9 +93,20 @@ bool SaslAuthenticator::available(void) } // Initialize the SASL mechanism; throw if it fails. -void SaslAuthenticator::init(const std::string& saslName) +void SaslAuthenticator::init(const std::string& saslName, std::string const & saslConfigPath ) { - int code = sasl_server_init(NULL, saslName.c_str()); + int code; + // If we are not given a specific sasl path, do + // nothing and allow the default to be used. + if ( ! saslConfigPath.empty() ) { + if(SASL_OK != (code=sasl_set_path(SASL_PATH_TYPE_CONFIG, const_cast<char *>(saslConfigPath.c_str())))) { + QPID_LOG(error, "SASL: sasl_set_path: [" << code << "] " ); + return; + } + QPID_LOG(info, "SASL: config path set to " << saslConfigPath ); + } + + code = sasl_server_init(NULL, saslName.c_str()); if (code != SASL_OK) { // TODO: Figure out who owns the char* returned by // sasl_errstring, though it probably does not matter much @@ -224,18 +235,20 @@ void CyrusAuthenticator::init() * which cannot specify a realm for the user that is * authenticating. */ + int code; + const char *realm = connection.getBroker().getOptions().realm.c_str(); - int code = sasl_server_new(BROKER_SASL_NAME, /* Service name */ - NULL, /* Server FQDN, gethostname() */ - realm, /* Authentication realm */ - NULL, /* Local IP, needed for some mechanism */ - NULL, /* Remote IP, needed for some mechanism */ - NULL, /* Callbacks */ - 0, /* Connection flags */ - &sasl_conn); + code = sasl_server_new(BROKER_SASL_NAME, /* Service name */ + NULL, /* Server FQDN, gethostname() */ + realm, /* Authentication realm */ + NULL, /* Local IP, needed for some mechanism */ + NULL, /* Remote IP, needed for some mechanism */ + NULL, /* Callbacks */ + 0, /* Connection flags */ + &sasl_conn); if (SASL_OK != code) { - QPID_LOG(info, "SASL: Connection creation failed: [" << code << "] " << sasl_errdetail(sasl_conn)); + QPID_LOG(error, "SASL: Connection creation failed: [" << code << "] " << sasl_errdetail(sasl_conn)); // TODO: Change this to an exception signaling // server error, when one is available Modified: qpid/trunk/qpid/cpp/src/qpid/broker/SaslAuthenticator.h URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/qpid/broker/SaslAuthenticator.h?rev=947748&r1=947747&r2=947748&view=diff ============================================================================== --- qpid/trunk/qpid/cpp/src/qpid/broker/SaslAuthenticator.h (original) +++ qpid/trunk/qpid/cpp/src/qpid/broker/SaslAuthenticator.h Mon May 24 18:25:46 2010 @@ -58,7 +58,7 @@ public: static bool available(void); // Initialize the SASL mechanism; throw if it fails. - static void init(const std::string& saslName); + static void init(const std::string& saslName, std::string const & saslConfigPath ); static void fini(void); static std::auto_ptr<SaslAuthenticator> createAuthenticator(Connection& connection, bool isShadow); Added: qpid/trunk/qpid/cpp/src/sasl.mk URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/sasl.mk?rev=947748&view=auto ============================================================================== --- qpid/trunk/qpid/cpp/src/sasl.mk (added) +++ qpid/trunk/qpid/cpp/src/sasl.mk Mon May 24 18:25:46 2010 @@ -0,0 +1,31 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +# +SASLTEST_DIR = tests/sasl_config +SASLTEST_CONF = $(SASLTEST_DIR)/qpidd.conf +SASLTEST_DB = $(SASLTEST_DIR)/qpidd.sasldb + +$(SASLTEST_DB): + echo zig | $(SASL_PASSWD) -c -p -f $(SASLTEST_DB) -u QPID zig + echo zag | $(SASL_PASSWD) -c -p -f $(SASLTEST_DB) -u QPID zag + +sasltestdbdir = $(SASLTEST_DIR) +sasltestdb_DATA = $(SASLTEST_DB) + +CLEANFILES=$(SASLTEST_DB) + Modified: qpid/trunk/qpid/cpp/src/tests/ForkedBroker.cpp URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/ForkedBroker.cpp?rev=947748&r1=947747&r2=947748&view=diff ============================================================================== --- qpid/trunk/qpid/cpp/src/tests/ForkedBroker.cpp (original) +++ qpid/trunk/qpid/cpp/src/tests/ForkedBroker.cpp Mon May 24 18:25:46 2010 @@ -40,7 +40,7 @@ return o; namespace qpid { namespace tests { -ForkedBroker::ForkedBroker(const Args& constArgs) { +ForkedBroker::ForkedBroker(const Args& constArgs) : running(false), exitStatus(0) { Args args(constArgs); Args::iterator i = find(args.begin(), args.end(), string("TMP_DATA_DIR")); if (i != args.end()) { @@ -79,6 +79,8 @@ void ForkedBroker::kill(int sig) { throw ErrnoException("wait for forked process failed"); if (WEXITSTATUS(status) != 0 && sig != 9) throw qpid::Exception(QPID_MSG("Forked broker exited with: " << WEXITSTATUS(status))); + running = false; + exitStatus = status; } bool isLogOption(const std::string& s) { @@ -122,6 +124,7 @@ void ForkedBroker::init(const Args& user else throw qpid::Exception("EOF reading port number from child."); } ::close(pipeFds[0]); + running = true; } else { // child ::close(pipeFds[0]); Modified: qpid/trunk/qpid/cpp/src/tests/ForkedBroker.h URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/ForkedBroker.h?rev=947748&r1=947747&r2=947748&view=diff ============================================================================== --- qpid/trunk/qpid/cpp/src/tests/ForkedBroker.h (original) +++ qpid/trunk/qpid/cpp/src/tests/ForkedBroker.h Mon May 24 18:25:46 2010 @@ -63,11 +63,15 @@ class ForkedBroker { int wait(); // Wait for exit, return exit status. uint16_t getPort() { return port; } pid_t getPID() { return pid; } + bool isRunning() { return running; } private: void init(const Args& args); + bool running; + int exitStatus; + pid_t pid; int port; std::string dataDir; Modified: qpid/trunk/qpid/cpp/src/tests/Makefile.am URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/Makefile.am?rev=947748&r1=947747&r2=947748&view=diff ============================================================================== --- qpid/trunk/qpid/cpp/src/tests/Makefile.am (original) +++ qpid/trunk/qpid/cpp/src/tests/Makefile.am Mon May 24 18:25:46 2010 @@ -314,7 +314,7 @@ TESTS_ENVIRONMENT = \ $(srcdir)/run_test system_tests = qpid-client-test quick_perftest quick_topictest run_header_test quick_txtest -TESTS += start_broker $(system_tests) python_tests stop_broker run_federation_tests run_acl_tests run_cli_tests replication_test +TESTS += start_broker $(system_tests) python_tests stop_broker run_federation_tests run_acl_tests run_cli_tests replication_test run_cluster_authentication_test EXTRA_DIST += \ run_test vg_check \ @@ -351,7 +351,8 @@ EXTRA_DIST += \ run_test.ps1 \ start_broker.ps1 \ stop_broker.ps1 \ - topictest.ps1 + topictest.ps1 \ + run_cluster_authentication_test check_LTLIBRARIES += libdlclose_noop.la libdlclose_noop_la_LDFLAGS = -module -rpath $(abs_builddir) @@ -364,7 +365,8 @@ CLEANFILES+=valgrind.out *.log *.vglog* LONG_TESTS+=start_broker fanout_perftest shared_perftest multiq_perftest topic_perftest run_ring_queue_test stop_broker \ run_failover_soak reliable_replication_test \ - federated_cluster_test_with_node_failure + federated_cluster_test_with_node_failure \ + run_cluster_authentication_soak EXTRA_DIST+= \ fanout_perftest \ @@ -373,7 +375,8 @@ EXTRA_DIST+= \ topic_perftest \ run_failover_soak \ reliable_replication_test \ - federated_cluster_test_with_node_failure + federated_cluster_test_with_node_failure \ + run_cluster_authentication_soak check-long: $(MAKE) check TESTS="$(LONG_TESTS)" VALGRIND= Modified: qpid/trunk/qpid/cpp/src/tests/cluster_authentication_soak.cpp URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/cluster_authentication_soak.cpp?rev=947748&r1=947747&r2=947748&view=diff ============================================================================== --- qpid/trunk/qpid/cpp/src/tests/cluster_authentication_soak.cpp (original) +++ qpid/trunk/qpid/cpp/src/tests/cluster_authentication_soak.cpp Mon May 24 18:25:46 2010 @@ -44,6 +44,10 @@ #include <qpid/client/Connection.h> +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + @@ -64,32 +68,42 @@ typedef vector<ForkedBroker *> brokerVec -int newbiePort = 0; +int runSilent = 1; +int newbiePort = 0; + +void +makeClusterName ( string & s ) { + stringstream ss; + ss << "authenticationSoakCluster_" << Uuid(true).str(); + s = ss.str(); +} void -startBroker ( brokerVector & brokers , - int brokerNumber ) { - stringstream portSS, prefix; +startBroker ( brokerVector & brokers , int brokerNumber, string const & clusterName ) { + stringstream prefix, clusterArg; prefix << "soak-" << brokerNumber; + clusterArg << "--cluster-name=" << clusterName; + std::vector<std::string> argv; argv.push_back ("../qpidd"); argv.push_back ("--no-module-dir"); argv.push_back ("--load-module=../.libs/cluster.so"); - argv.push_back ("--cluster-name=micks_test_cluster"); - argv.push_back ("--cluster-username=guest"); - argv.push_back ("--cluster-password=guest"); + argv.push_back (clusterArg.str().c_str()); + argv.push_back ("--cluster-username=zig"); + argv.push_back ("--cluster-password=zig"); argv.push_back ("--cluster-mechanism=ANONYMOUS"); - argv.push_back ("TMP_DATA_DIR"); + argv.push_back ("--sasl-config=./sasl_config"); argv.push_back ("--auth=yes"); argv.push_back ("--mgmt-enable=yes"); argv.push_back ("--log-prefix"); argv.push_back (prefix.str()); argv.push_back ("--log-to-file"); argv.push_back (prefix.str()+".log"); + argv.push_back ("TMP_DATA_DIR"); ForkedBroker * newbie = new ForkedBroker (argv); newbiePort = newbie->getPort(); @@ -100,7 +114,7 @@ startBroker ( brokerVector & brokers , bool -runPerftest ( ) { +runPerftest ( bool hangTest ) { stringstream portSs; portSs << newbiePort; @@ -111,9 +125,9 @@ runPerftest ( ) { argv.push_back ( "-p" ); argv.push_back ( portSs.str().c_str() ); argv.push_back ( "--username" ); - argv.push_back ( "guest" ); + argv.push_back ( "zig" ); argv.push_back ( "--password" ); - argv.push_back ( "guest" ); + argv.push_back ( "zig" ); argv.push_back ( "--mechanism" ); argv.push_back ( "DIGEST-MD5" ); argv.push_back ( "--count" ); @@ -133,6 +147,12 @@ runPerftest ( ) { return false; } else { + if ( hangTest ) { + if ( ! runSilent ) + cerr << "Pausing perftest " << pid << endl; + kill ( pid, 19 ); + } + struct timeval startTime, currentTime, duration; @@ -140,7 +160,7 @@ runPerftest ( ) { gettimeofday ( & startTime, 0 ); while ( 1 ) { - sleep ( 5 ); + sleep ( 2 ); int status; int returned_pid = waitpid ( pid, &status, WNOHANG ); if ( returned_pid == pid ) { @@ -171,14 +191,9 @@ runPerftest ( ) { bool allBrokersAreAlive ( brokerVector & brokers ) { - for ( unsigned int i = 0; i < brokers.size(); ++ i ) { - pid_t pid = brokers[i]->getPID(); - int status; - int value; - if ( (value = waitpid ( pid, &status, WNOHANG ) ) ) { - return false; - } - } + for ( unsigned int i = 0; i < brokers.size(); ++ i ) + if ( ! brokers[i]->isRunning() ) + return false; return true; } @@ -186,10 +201,23 @@ allBrokersAreAlive ( brokerVector & brok + void killAllBrokers ( brokerVector & brokers ) { - for ( unsigned int i = 0; i < brokers.size(); ++ i ) + for ( unsigned int i = 0; i < brokers.size(); ++ i ) { brokers[i]->kill ( 9 ); + } +} + + + + +void +killOneBroker ( brokerVector & brokers ) { + int doomedBroker = getpid() % brokers.size(); + cout << "Killing broker " << brokers[doomedBroker]->getPID() << endl; + brokers[doomedBroker]->kill ( 9 ); + sleep ( 2 ); } @@ -201,15 +229,36 @@ using namespace qpid::tests; +/* + * Please note that this test has self-test capability. + * It is intended to detect + * 1. perftest hangs. + * 2. broker deaths + * Both of these condtions can be forced when running manually + * to ensure that the test really does detect them. + * See command-line arguments 3 and 4. + */ int main ( int argc, char ** argv ) { - int n_iterations = argc > 0 ? atoi(argv[1]) : 1; + int n_iterations = argc > 1 ? atoi(argv[1]) : 1; + runSilent = argc > 2 ? atoi(argv[2]) : 1; // default to silent + int killBroker = argc > 3 ? atoi(argv[3]) : 0; // Force the kill of one broker. + int hangTest = argc > 4 ? atoi(argv[4]) : 0; // Force the first perftest to hang. int n_brokers = 3; brokerVector brokers; + #ifndef HAVE_SASL + if ( ! runSilent ) + cout << "No SASL support. cluster_authentication_soak disabled."; + return 0; + #endif + + srand ( getpid() ); + string clusterName; + makeClusterName ( clusterName ); for ( int i = 0; i < n_brokers; ++ i ) { - startBroker ( brokers, i ); + startBroker ( brokers, i, clusterName ); } sleep ( 3 ); @@ -221,22 +270,38 @@ main ( int argc, char ** argv ) * set to 1. */ for ( int iteration = 0; iteration < n_iterations; ++ iteration ) { - if ( ! runPerftest ( ) ) { - cerr << "qpid-perftest " << iteration << " failed.\n"; + if ( ! runPerftest ( hangTest ) ) { + if ( ! runSilent ) + cerr << "qpid-perftest " << iteration << " failed.\n"; return 1; } if ( ! ( iteration % 10 ) ) { - cerr << "qpid-perftest " << iteration << " complete. -------------- \n"; + if ( ! runSilent ) + cerr << "qpid-perftest " << iteration << " complete. -------------- \n"; } } - cerr << "\nqpid-perftest " << n_iterations << " iterations complete. -------------- \n\n"; + if ( ! runSilent ) + cerr << "\nqpid-perftest " << n_iterations << " iterations complete. -------------- \n\n"; + + /* If the command-line tells us to kill a broker, do + * it now. Use this option to prove that this test + * really can detect broker-deaths. + */ + if ( killBroker ) { + killOneBroker ( brokers ); + } if ( ! allBrokersAreAlive ( brokers ) ) { - cerr << "not all brokers are alive.\n"; + if ( ! runSilent ) + cerr << "not all brokers are alive.\n"; + killAllBrokers ( brokers ); return 2; } killAllBrokers ( brokers ); + if ( ! runSilent ) + cout << "success.\n"; + return 0; } Added: qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_soak URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_soak?rev=947748&view=auto ============================================================================== --- qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_soak (added) +++ qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_soak Mon May 24 18:25:46 2010 @@ -0,0 +1,4 @@ +#! /bin/bash + +./cluster_authentication_soak 500 + Propchange: qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_soak ------------------------------------------------------------------------------ svn:executable = * Added: qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_test URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_test?rev=947748&view=auto ============================================================================== --- qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_test (added) +++ qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_test Mon May 24 18:25:46 2010 @@ -0,0 +1,4 @@ +#! /bin/bash + +./cluster_authentication_soak + Propchange: qpid/trunk/qpid/cpp/src/tests/run_cluster_authentication_test ------------------------------------------------------------------------------ svn:executable = * Added: qpid/trunk/qpid/cpp/src/tests/sasl_config/qpidd.conf URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/sasl_config/qpidd.conf?rev=947748&view=auto ============================================================================== --- qpid/trunk/qpid/cpp/src/tests/sasl_config/qpidd.conf (added) +++ qpid/trunk/qpid/cpp/src/tests/sasl_config/qpidd.conf Mon May 24 18:25:46 2010 @@ -0,0 +1,45 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +# +# +# This configuation allows for either SASL PLAIN or ANONYMOUS +# authentication. The PLAIN authentication is done on a +# username+password, which is stored in the sasldb_path +# file. Usernames and passwords can be added to the file using the +# command: +# +# saslpasswd2 -f /var/lib/qpidd/qpidd.sasldb -u <REALM> <USER> +# +# The REALM is important and should be the same as the --auth-realm +# option to the broker. This lets the broker properly find the user in +# the sasldb file. +# +# Existing user accounts may be listed with: +# +# sasldblistusers2 -f /var/lib/qpidd/qpidd.sasldb +# +# NOTE: The sasldb file must be readable by the user running the qpidd +# daemon, and should be readable only by that user. +# +pwcheck_method: auxprop +auxprop_plugin: sasldb +sasldb_path: ./sasl_config/qpidd.sasldb + +#following line stops spurious 'sql_select option missing' errors when +#cyrus-sql-sasl plugin is installed +sql_select: dummy select --------------------------------------------------------------------- Apache Qpid - AMQP Messaging Implementation Project: http://qpid.apache.org Use/Interact: mailto:commits-subscr...@qpid.apache.org