@borrrden yes, I have stumbled upon that detail while digging.
I’m still struggling to understand how databases and users work. For instance, I have a database configured with a user name and password. Through the server dashboard I have created a bucket. But if I use the sync-gateway admin api to create a database, I can’t see it through the server dashboard. Neither I can see created users.
Also, the API explorer for the databases call doesn’t seem to be working correctly. It doesn’t seem to fill the curl properly so I need to write the escaped JSON by hand which takes me much more time to explore the API.
C you please tell me exactly which headers (or point me a document where that is specified) should I use in the authentication process of the websocket open?
I’m using the QCBLWebSocket class made available by this project as a wrapper to couchbase-lite-core in Qt. I’m using Qt myself too.
While I’m passing the auth info to the replicator initialisation the fact is that it doesn’t seem to be used during websocket open.
I have a question. What’s the name of the auth headers that sync gateway expects to receive in the other side?
for (Dict::iterator header(options.get(kC4ReplicatorOptionAuthentication).asDict()); header; ++header)
This are the keys there are being filled upon replicator construction. Inside the socket they must be put into the Raw Header.
#define kC4ReplicatorOptionAuthentication “auth”
#define kC4AuthTypeBasic “Basic”
#define kC4ReplicatorAuthType “type”
#define kC4ReplicatorAuthUserName “username”
#define kC4ReplicatorAuthPassword “password”
How should I place this info into the Raw Headers? Because I have already tried the way above and the result is exactly the same, sync-gateway is logging that the request requires authentication.
Thanks in advance!