]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3:netapi: Get username/password from cli_credentials in netapi.c
authorAndreas Schneider <asn@samba.org>
Thu, 18 Mar 2021 10:12:09 +0000 (11:12 +0100)
committerGünther Deschner <gd@samba.org>
Wed, 24 Mar 2021 00:55:32 +0000 (00:55 +0000)
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
source3/lib/netapi/netapi.c

index ea67ecdec5a25fc14031d5681fec852e2304ad4b..21890ecfabc43a937fdb0748c760757568f72c28 100644 (file)
@@ -255,7 +255,7 @@ NET_API_STATUS libnetapi_get_username(struct libnetapi_ctx *ctx,
        }
 
        if (username != NULL) {
-               *username = ctx->username;
+               *username = cli_credentials_get_username(ctx->creds);
        }
 
        return NET_API_STATUS_SUCCESS;
@@ -278,7 +278,7 @@ NET_API_STATUS libnetapi_get_password(struct libnetapi_ctx *ctx,
        }
 
        if (password != NULL) {
-               *password = ctx->password;
+               *password = cli_credentials_get_password(ctx->creds);
        }
 
        return NET_API_STATUS_SUCCESS;