-
Notifications
You must be signed in to change notification settings - Fork 137
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
smb2_get_error "Tree Connect failed with (0xc0000022) STATUS_ACCESS_DENIED" while using negotiate version 0311 to connect some linux servers. #209
Comments
On Sat, Aug 7, 2021 at 9:56 PM Arlen-LT ***@***.***> wrote:
I pull from commit d8c85a3
<d8c85a3>.
My code is:
smb2_context* smb2 = smb2_init_context();
smb2_set_security_mode(smb2, SMB2_NEGOTIATE_SIGNING_ENABLED);
smb2_set_timeout(smb2, 3);
int ret = smb2_connect_share(smb2, ip, share, userID, password);
if(ret < 0)
{
Log("%s\n", smb2_get_error(smb2));
smb2_disconnect_share(smb2);
smb2_destroy_context(smb2);
smb2 = nullptr;
}
and the error message is Tree Connect failed with (0xc0000022)
STATUS_ACCESS_DENIED.
I tried to use smb2_set_version(smb2, SMB2_VERSION_0302); or any other
negotiate version below SMB2_VERSION_0311 and connect successfully.
Could someone give me some advice? Thanks a lot.
Access denied is an error from the server, it means that the user you
authenticate as does not have permission to access the share.
… —
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#209>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AADY3EH7OJAIZRQUHXB4SNTT3UNQLANCNFSM5BXK3JTA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email>
.
|
When I set the negotiate version as SMB2_VERSION_0302, everything works well with the same server and the same share, this is just happening while using Anonymous. |
I pull from commit d8c85a3. My code is:
and the error message is
Tree Connect failed with (0xc0000022) STATUS_ACCESS_DENIED.
I tried to use
smb2_set_version(smb2, SMB2_VERSION_0302);
or any other negotiate version below SMB2_VERSION_0311 and connect successfully.Could someone give me some advice? Thanks a lot.
The text was updated successfully, but these errors were encountered: