]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3:net_rpc: make use of !c->explicit_credentials for NET_FLAGS_ANONYMOUS
authorStefan Metzmacher <metze@samba.org>
Thu, 7 Mar 2024 12:43:13 +0000 (13:43 +0100)
committerStefan Metzmacher <metze@samba.org>
Tue, 14 May 2024 10:18:31 +0000 (10:18 +0000)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
source3/utils/net_rpc.c

index 2b904fb55331636a13cea27c1d5ada6c85732308..c7f0126c4658afffbc2fc2c1d8fa4d48a4540e92 100644 (file)
@@ -319,7 +319,7 @@ int net_rpc_changetrustpw(struct net_context *c, int argc, const char **argv)
 {
        int conn_flags = NET_FLAGS_PDC;
 
-       if (!c->opt_user_specified && !c->opt_kerberos) {
+       if (!c->explicit_credentials) {
                conn_flags |= NET_FLAGS_ANONYMOUS;
        }
 
@@ -879,7 +879,7 @@ int net_rpc_getsid(struct net_context *c, int argc, const char **argv)
 {
        int conn_flags = NET_FLAGS_PDC;
 
-       if (!c->opt_user_specified && !c->opt_kerberos) {
+       if (!c->explicit_credentials) {
                conn_flags |= NET_FLAGS_ANONYMOUS;
        }