1
0
mirror of https://github.com/samba-team/samba.git synced 2025-12-17 04:23:50 +03:00

python: move system_session_unix to new auth_util.py

system_session_unix() will be used by many more callers soon.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
This commit is contained in:
Ralph Boehme
2019-12-16 18:00:26 +01:00
parent 459233b962
commit cfc0ca7337
2 changed files with 36 additions and 12 deletions

View File

@@ -25,13 +25,10 @@ from samba.ndr import ndr_unpack, ndr_print
from samba.samdb import SamDB
from samba.samba3 import param as s3param, passdb, smbd
from samba import provision
from samba.auth_util import system_session_unix
import os
from samba.auth import (
system_session,
session_info_fill_unix,
copy_session_info,
)
from samba.auth import system_session
from samba.netcmd import (
Command,
@@ -40,13 +37,6 @@ from samba.netcmd import (
Option,
)
def system_session_unix():
session_info = system_session()
session_info_unix = copy_session_info(session_info)
session_info_fill_unix(session_info_unix, None)
return session_info_unix
def get_local_domain_sid(lp):
is_ad_dc = False
server_role = lp.server_role()