You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Calling get_mode on a Windows machine which is a member of a domain but which is disconnected from its domain controller produces an exception from win32security.LookupAccountSid().
Your configuration
Windows 10 x64, Python 3.7, oschmod==0.3.9
Steps to reproduce
oschmod.get_mode(pathname)
What happened
Traceback (most recent call last)
File "...\oschmod\__init__.py", line 163, in get_mode
return win_get_permissions(path)
File "...\oschmod\__init__.py", line 364, in win_get_permissions
return _win_get_permissions(path, get_object_type(path))
File "...\oschmod\__init__.py", line 387, in _win_get_permissions
win32security.LookupAccountSid(None, ace[2]) != \
pywintypes.error: (1789, 'LookupAccountSid', 'The trust relationship between this workstation and the primary domain controller failed.')
Additional context
I'm not an expert in windows security (traceback was retyped from a screenshot of a teamviewer session!) so am not sure if this is even resolvable or oschmod's problem. But apparently being part of a domain, but not connected to a domain controller, is a reasonable scenario for Windows devices.
The text was updated successfully, but these errors were encountered:
Thanks for raising this issue! My apologies for not getting back to you. I'll definitely take a look at this. Perhaps there's some easy error handling that will allow this to work despite the exception.
Describe the bug
Calling
get_mode
on a Windows machine which is a member of a domain but which is disconnected from its domain controller produces an exception fromwin32security.LookupAccountSid()
.Your configuration
Windows 10 x64, Python 3.7, oschmod==0.3.9
Steps to reproduce
oschmod.get_mode(pathname)
What happened
Additional context
I'm not an expert in windows security (traceback was retyped from a screenshot of a teamviewer session!) so am not sure if this is even resolvable or oschmod's problem. But apparently being part of a domain, but not connected to a domain controller, is a reasonable scenario for Windows devices.
The text was updated successfully, but these errors were encountered: