Skip to content

Commit

Permalink
Merge pull request #1730 from pi-hole/fix/2fa-domain
Browse files Browse the repository at this point in the history
Use webserver.domain as "account" in the TOTP QR code
  • Loading branch information
DL6ER committed Nov 4, 2023
2 parents 73e265a + ff3b8db commit afb6f86
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/api/2fa.c
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ int generateTOTP(struct ftl_conn *api)
// Create JSON object
cJSON *tjson = cJSON_CreateObject();
JSON_REF_STR_IN_OBJECT(tjson, "type", "totp");
JSON_REF_STR_IN_OBJECT(tjson, "account", "pi.hole");
JSON_REF_STR_IN_OBJECT(tjson, "account", config.webserver.domain.v.s);
JSON_REF_STR_IN_OBJECT(tjson, "issuer", "Pi-hole%20API");
JSON_REF_STR_IN_OBJECT(tjson, "algorithm", "SHA1");
JSON_ADD_NUMBER_TO_OBJECT(tjson, "digits", RFC6238_DIGITS);
Expand Down

0 comments on commit afb6f86

Please sign in to comment.