mirror of
https://github.com/emqx/neuron.git
synced 2026-10-18 13:41:22 +08:00
change default password
This commit is contained in:
@@ -7,11 +7,11 @@ Suite Teardown Stop Neuronx
|
||||
|
||||
*** Test Cases ***
|
||||
login with invalid username and password, it should return failure
|
||||
POST /api/v2/login {"name":"admin1", "pass": "0000"}
|
||||
POST /api/v2/login {"name":"admin1", "pass": "Lrlq6si6%GUvok$B"}
|
||||
Integer response status 401
|
||||
Integer $.error ${NEU_ERR_INVALID_USER_OR_PASSWORD}
|
||||
|
||||
login with username and password, it should return success
|
||||
POST /api/v2/login {"name":"admin", "pass": "0000"}
|
||||
POST /api/v2/login {"name":"admin", "pass": "Lrlq6si6%GUvok$B"}
|
||||
Integer response status 200
|
||||
output $.token
|
||||
|
||||
@@ -53,7 +53,7 @@ Check Response Status
|
||||
Integer response status ${status}
|
||||
|
||||
LOGIN
|
||||
POST /api/v2/login {"name": "admin", "pass":"0000"}
|
||||
POST /api/v2/login {"name": "admin", "pass":"Lrlq6si6%GUvok$B"}
|
||||
|
||||
Integer response status 200
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@ void handle_login(nng_aio *aio)
|
||||
aio, neu_json_login_req_t, neu_json_decode_login_req, {
|
||||
neu_json_login_resp_t login_resp = { 0 };
|
||||
char * name = "admin";
|
||||
char * password = "0000";
|
||||
char * password = "Lrlq6si6%GUvok$B";
|
||||
|
||||
if (strcmp(req->name, name) == 0 &&
|
||||
strcmp(req->pass, password) == 0) {
|
||||
|
||||
Reference in New Issue
Block a user