summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2011-07-22 12:15:06 +1000
committerAndrew Bartlett <abartlet@samba.org>2011-08-03 18:48:03 +1000
commitbba5f0a6418db2fd5a65e5f72a5a93dc8c7c0240 (patch)
treeeec80cf7a74e186efe05ea9e324297d52e470dce /source3
parent778bf87d8dbae333bfeea3b0d904fd2b17782745 (diff)
downloadsamba-bba5f0a6418db2fd5a65e5f72a5a93dc8c7c0240.tar.gz
samba-bba5f0a6418db2fd5a65e5f72a5a93dc8c7c0240.tar.bz2
samba-bba5f0a6418db2fd5a65e5f72a5a93dc8c7c0240.zip
s3-ntlmssp Remove auth_ntlmssp_or_flags
We now just use auth_ntlmssp_want_feature to get extra flags on the NTLMSSP context Andrew Bartlett Signed-off-by: Andrew Tridgell <tridge@samba.org>
Diffstat (limited to 'source3')
-rw-r--r--source3/include/ntlmssp_wrap.h1
-rw-r--r--source3/librpc/crypto/cli_spnego.c9
-rw-r--r--source3/libsmb/clifsinfo.c2
-rw-r--r--source3/libsmb/ntlmssp_wrap.c5
-rw-r--r--source3/rpc_client/cli_pipe.c5
5 files changed, 7 insertions, 15 deletions
diff --git a/source3/include/ntlmssp_wrap.h b/source3/include/ntlmssp_wrap.h
index 7cdc2d9020..303595dcdd 100644
--- a/source3/include/ntlmssp_wrap.h
+++ b/source3/include/ntlmssp_wrap.h
@@ -73,7 +73,6 @@ NTSTATUS auth_ntlmssp_set_domain(struct auth_ntlmssp_state *ans,
NTSTATUS auth_ntlmssp_set_password(struct auth_ntlmssp_state *ans,
const char *password);
void auth_ntlmssp_and_flags(struct auth_ntlmssp_state *ans, uint32_t flags);
-void auth_ntlmssp_or_flags(struct auth_ntlmssp_state *ans, uint32_t flags);
void auth_ntlmssp_want_feature(struct auth_ntlmssp_state *ans, uint32_t feature);
DATA_BLOB auth_ntlmssp_get_session_key(struct auth_ntlmssp_state *ans,
TALLOC_CTX *mem_ctx);
diff --git a/source3/librpc/crypto/cli_spnego.c b/source3/librpc/crypto/cli_spnego.c
index 3222d0b7ef..c30a297cc5 100644
--- a/source3/librpc/crypto/cli_spnego.c
+++ b/source3/librpc/crypto/cli_spnego.c
@@ -138,12 +138,11 @@ NTSTATUS spnego_ntlmssp_init_client(TALLOC_CTX *mem_ctx,
NTLMSSP_NEGOTIATE_SEAL));
if (do_sign) {
- auth_ntlmssp_or_flags(sp_ctx->mech_ctx.ntlmssp_state,
- NTLMSSP_NEGOTIATE_SIGN);
+ auth_ntlmssp_want_feature(sp_ctx->mech_ctx.ntlmssp_state,
+ NTLMSSP_FEATURE_SIGN);
} else if (do_seal) {
- auth_ntlmssp_or_flags(sp_ctx->mech_ctx.ntlmssp_state,
- NTLMSSP_NEGOTIATE_SEAL |
- NTLMSSP_NEGOTIATE_SIGN);
+ auth_ntlmssp_want_feature(sp_ctx->mech_ctx.ntlmssp_state,
+ NTLMSSP_FEATURE_SEAL);
}
*spnego_ctx = sp_ctx;
diff --git a/source3/libsmb/clifsinfo.c b/source3/libsmb/clifsinfo.c
index 3e268b5e6f..9005d4dac4 100644
--- a/source3/libsmb/clifsinfo.c
+++ b/source3/libsmb/clifsinfo.c
@@ -623,7 +623,7 @@ NTSTATUS cli_raw_ntlm_smb_encryption_start(struct cli_state *cli,
}
auth_ntlmssp_want_feature(es->s.auth_ntlmssp_state, NTLMSSP_FEATURE_SESSION_KEY);
- auth_ntlmssp_or_flags(es->s.auth_ntlmssp_state, NTLMSSP_NEGOTIATE_SIGN|NTLMSSP_NEGOTIATE_SEAL);
+ auth_ntlmssp_want_feature(es->s.auth_ntlmssp_state, NTLMSSP_FEATURE_SEAL);
if (!NT_STATUS_IS_OK(status = auth_ntlmssp_set_username(es->s.auth_ntlmssp_state, user))) {
goto fail;
diff --git a/source3/libsmb/ntlmssp_wrap.c b/source3/libsmb/ntlmssp_wrap.c
index 454720423a..817dc62910 100644
--- a/source3/libsmb/ntlmssp_wrap.c
+++ b/source3/libsmb/ntlmssp_wrap.c
@@ -148,11 +148,6 @@ void auth_ntlmssp_and_flags(struct auth_ntlmssp_state *ans, uint32_t flags)
ans->ntlmssp_state->neg_flags &= flags;
}
-void auth_ntlmssp_or_flags(struct auth_ntlmssp_state *ans, uint32_t flags)
-{
- ans->ntlmssp_state->neg_flags |= flags;
-}
-
void auth_ntlmssp_want_feature(struct auth_ntlmssp_state *ans, uint32_t feature)
{
if (ans->gensec_security) {
diff --git a/source3/rpc_client/cli_pipe.c b/source3/rpc_client/cli_pipe.c
index 3224f09e27..c2e28188b9 100644
--- a/source3/rpc_client/cli_pipe.c
+++ b/source3/rpc_client/cli_pipe.c
@@ -2363,10 +2363,9 @@ static NTSTATUS rpccli_ntlmssp_bind_data(TALLOC_CTX *mem_ctx,
NTLMSSP_NEGOTIATE_SEAL));
if (auth_level == DCERPC_AUTH_LEVEL_INTEGRITY) {
- auth_ntlmssp_or_flags(ntlmssp_ctx, NTLMSSP_NEGOTIATE_SIGN);
+ auth_ntlmssp_want_feature(ntlmssp_ctx, NTLMSSP_FEATURE_SIGN);
} else if (auth_level == DCERPC_AUTH_LEVEL_PRIVACY) {
- auth_ntlmssp_or_flags(ntlmssp_ctx, NTLMSSP_NEGOTIATE_SEAL |
- NTLMSSP_NEGOTIATE_SIGN);
+ auth_ntlmssp_want_feature(ntlmssp_ctx, NTLMSSP_FEATURE_SEAL);
}
result->auth_ctx = ntlmssp_ctx;