mirror of
https://github.com/vanhauser-thc/thc-hydra.git
synced 2025-07-06 04:51:40 -07:00
fix mongodb module not using user specified port
This commit is contained in:
parent
022790867d
commit
4a1bb5117f
1 changed files with 1 additions and 1 deletions
|
@ -72,7 +72,7 @@ int32_t start_mongodb(int32_t s, char *ip, int32_t port, unsigned char options,
|
||||||
mongoc_log_set_handler(NULL, NULL);
|
mongoc_log_set_handler(NULL, NULL);
|
||||||
bson_init(&q);
|
bson_init(&q);
|
||||||
|
|
||||||
snprintf(uri, sizeof(uri), "mongodb://%s:%s@%s/?authSource=%s", login, pass, hydra_address2string(ip), miscptr);
|
snprintf(uri, sizeof(uri), "mongodb://%s:%s@%s:%d/?authSource=%s", login, pass, hydra_address2string(ip), port, miscptr);
|
||||||
client = mongoc_client_new(uri);
|
client = mongoc_client_new(uri);
|
||||||
if (!client)
|
if (!client)
|
||||||
return 3;
|
return 3;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue