Skip to content

Commit 68ab339

Browse files
Cheruvu.Sahithee.Vaibhav@ibm.comCheruvu.Sahithee.Vaibhav@ibm.com
authored andcommitted
remove authority host as user param
1 parent 5d69a0d commit 68ab339

2 files changed

Lines changed: 2 additions & 20 deletions

File tree

plugins/out_azure_blob/azure_blob.c

Lines changed: 2 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1421,17 +1421,6 @@ static int cb_azure_blob_init(struct flb_output_instance *ins,
14211421
if (ctx->atype == AZURE_BLOB_AUTH_SERVICE_PRINCIPAL) {
14221422
pthread_mutex_init(&ctx->token_mutex, NULL);
14231423
flb_sds_t token_url;
1424-
const char *authority_host;
1425-
size_t authority_len;
1426-
1427-
authority_host = ctx->azure_authority_host ?
1428-
ctx->azure_authority_host :
1429-
AZURE_BLOB_DEFAULT_AUTHORITY_HOST;
1430-
1431-
authority_len = strlen(authority_host);
1432-
if (authority_len > 0 && authority_host[authority_len - 1] == '/') {
1433-
authority_len--;
1434-
}
14351424

14361425
token_url = flb_sds_create_size(256);
14371426
if (!token_url) {
@@ -1440,8 +1429,8 @@ static int cb_azure_blob_init(struct flb_output_instance *ins,
14401429
}
14411430

14421431
ret = flb_sds_snprintf(&token_url, flb_sds_alloc(token_url),
1443-
"%.*s/%s/oauth2/v2.0/token",
1444-
(int)authority_len, authority_host, ctx->tenant_id);
1432+
"%s/%s/oauth2/v2.0/token",
1433+
AZURE_BLOB_DEFAULT_AUTHORITY_HOST, ctx->tenant_id);
14451434
if (ret < 0) {
14461435
flb_plg_error(ctx->ins, "failed to build token URL");
14471436
flb_sds_destroy(token_url);
@@ -2589,12 +2578,6 @@ static struct flb_config_map config_map[] = {
25892578
"Azure AD client secret (required for service_principal auth)"
25902579
},
25912580

2592-
{
2593-
FLB_CONFIG_MAP_STR, "azure_authority_host", "https://login.microsoftonline.com",
2594-
0, FLB_TRUE, offsetof(struct flb_azure_blob, azure_authority_host),
2595-
"Azure authority host for OAuth2 token endpoint (optional, defaults to https://login.microsoftonline.com)"
2596-
},
2597-
25982581
{
25992582
FLB_CONFIG_MAP_STR, "database_file", NULL,
26002583
0, FLB_TRUE, offsetof(struct flb_azure_blob, database_file),

plugins/out_azure_blob/azure_blob.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,6 @@ struct flb_azure_blob {
8181
flb_sds_t tenant_id;
8282
flb_sds_t client_id;
8383
flb_sds_t client_secret;
84-
flb_sds_t azure_authority_host;
8584
flb_sds_t database_file;
8685
size_t part_size;
8786
time_t upload_parts_timeout;

0 commit comments

Comments
 (0)