mctestauth
- reference
The mctestauth tool allows you to troubleshoot authentication issues in data services.
Description
The mctestauth
tool allows you to troubleshoot the authentication issues in data services. Data services use the Simple Authentication and Security Layer (SASL) framework for authentication and provide you access to use the underlying mechanisms. For example, SCRAM-SHA512 or PLAIN.
The tool is located as follows:
Platform | Location |
---|---|
Linux |
/opt/couchbase/bin/mctestauth |
Windows |
C:\Program Files\Couchbase\Server\bin\mctestauth.exe |
Mac OS X |
/Applications/Couchbase Server.app/Contents/Resources/couchbase-core/bin/mctestauth |
Syntax
mctestauth [options]
The options
are as follows:
Options | Description |
---|---|
|
The name of the host (with an optional port) to connect to. For IPv6, use |
|
The username to be used in authentication. |
|
The password to be used in authentication. |
|
Optionally, use TLS to authenticate. |
|
Connect over IPv4. |
|
Connect over IPv6. |
|
Find program version. |
|
Print output without any colors. |
|
Display help text. |
Example
The following call tries to connect to the data server running on the host 192.168.86.101
. The call then tries the various authentication mechanisms supported by the server and prints out the result of each mechanism. The call succeeds only if you provide the correct credentials.
./mctestauth --host 192.168.86.101 --user jones --password password
If successful, the command returns output as follows:
SCRAM-SHA512: OK SCRAM-SHA256: OK SCRAM-SHA1: OK PLAIN: OK
If jones
was defined as an external user in LDAP, the output is as follows:
SCRAM-SHA512: FAILED SCRAM-SHA256: FAILED SCRAM-SHA1: FAILED PLAIN: OK